By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,524 Members | 1,475 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,524 IT Pros & Developers. It's quick & easy.

Screen Resolutions

P: n/a
Me
I am about to roll out a vb.net 2003 app for screens
using 1024x768.

However some users will only have 800x600. Is there
a quick method of scaling down the screens already written
(e.g. SystemMetrics or Anchor points etc....) for these
users ? There are no bitmaps or images in this app, only
textboxes, listviews, forms and buttons.

TIA
Me
Nov 20 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a
* "Me" <an*******@discussions.microsoft.com> scripsit:
I am about to roll out a vb.net 2003 app for screens
using 1024x768.

However some users will only have 800x600. Is there
a quick method of scaling down the screens already written
(e.g. SystemMetrics or Anchor points etc....) for these
users ? There are no bitmaps or images in this app, only
textboxes, listviews, forms and buttons.


Have a look at the controls' 'Anchor' and 'Dock' properties and/or at
the form's 'Scale' method.

--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Nov 20 '05 #2

P: n/a
Cor
Hi Me,

I never used it (written 10 minutes ago), however when I saw your message I
had to think on this.
You can try it,

Can be fun with a timer I did think: zooming in and out, but to keep it
simple for you I did not paste that code in.

Give some message if it works for you?

Cor

\\\
Private Sub Button1_Click(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles Button1.Click
Me.Width = CInt(Me.Width * 0.8)
Me.Height = CInt(Me.Height * 0.8)
Dim nada As New doCtr(Me)
End Sub
End Class
Public Class doCtr
Public Sub New(ByVal parentCtr As Control)
Dim ctr As Control
For Each ctr In parentCtr.Controls
ctr.Left = CInt(ctr.Left * 0.8)
ctr.Top = CInt(ctr.Top * 0.8)
ctr.Width = CInt(ctr.Width * 0.8)
ctr.Height = CInt(ctr.Height * 0.8)
Dim newdoCtr As _
New doCtr(ctr)
Next
End Sub
///

However some users will only have 800x600. Is there
a quick method of scaling down the screens already written
(e.g. SystemMetrics or Anchor points etc....) for these
users ? There are no bitmaps or images in this app, only
textboxes, listviews, forms and buttons.

TIA
Me

Nov 20 '05 #3

P: n/a
Me
Yes that's just what's needed - nice and quick too.
-Your timer idea also sounds like a nice 'feature' to
try on someone...

Thanks
-----Original Message-----
Hi Me,

I never used it (written 10 minutes ago), however when I saw your message Ihad to think on this.
You can try it,

Can be fun with a timer I did think: zooming in and out, but to keep itsimple for you I did not paste that code in.

Give some message if it works for you?

Cor

\\\
Private Sub Button1_Click(ByVal sender As System.Object, _ ByVal e As System.EventArgs) Handles Button1.Click
Me.Width = CInt(Me.Width * 0.8)
Me.Height = CInt(Me.Height * 0.8)
Dim nada As New doCtr(Me)
End Sub
End Class
Public Class doCtr
Public Sub New(ByVal parentCtr As Control)
Dim ctr As Control
For Each ctr In parentCtr.Controls
ctr.Left = CInt(ctr.Left * 0.8)
ctr.Top = CInt(ctr.Top * 0.8)
ctr.Width = CInt(ctr.Width * 0.8)
ctr.Height = CInt(ctr.Height * 0.8)
Dim newdoCtr As _
New doCtr(ctr)
Next
End Sub
///

However some users will only have 800x600. Is there
a quick method of scaling down the screens already written (e.g. SystemMetrics or Anchor points etc....) for these
users ? There are no bitmaps or images in this app, only textboxes, listviews, forms and buttons.

TIA
Me

.

Nov 20 '05 #4

P: n/a
Me
I forgot to ask... How can I tell the current
Screen res ?

Thanks
Me
-----Original Message-----
Hi Me,

I never used it (written 10 minutes ago), however when I saw your message Ihad to think on this.
You can try it,

Can be fun with a timer I did think: zooming in and out, but to keep itsimple for you I did not paste that code in.

Give some message if it works for you?

Cor

\\\
Private Sub Button1_Click(ByVal sender As System.Object, _ ByVal e As System.EventArgs) Handles Button1.Click
Me.Width = CInt(Me.Width * 0.8)
Me.Height = CInt(Me.Height * 0.8)
Dim nada As New doCtr(Me)
End Sub
End Class
Public Class doCtr
Public Sub New(ByVal parentCtr As Control)
Dim ctr As Control
For Each ctr In parentCtr.Controls
ctr.Left = CInt(ctr.Left * 0.8)
ctr.Top = CInt(ctr.Top * 0.8)
ctr.Width = CInt(ctr.Width * 0.8)
ctr.Height = CInt(ctr.Height * 0.8)
Dim newdoCtr As _
New doCtr(ctr)
Next
End Sub
///

However some users will only have 800x600. Is there
a quick method of scaling down the screens already written (e.g. SystemMetrics or Anchor points etc....) for these
users ? There are no bitmaps or images in this app, only textboxes, listviews, forms and buttons.

TIA
Me

.

Nov 20 '05 #5

P: n/a
* "Me" <an*******@discussions.microsoft.com> scripsit:
I forgot to ask... How can I tell the current
Screen res ?


'SystemInformation.PrimaryMonitorSize'
'SystemInformation.WorkingArea'
'SystemInformation.VirtualScreen'
'Screen.PrimaryScreen.Bounds'
'Screen.PrimaryScreen.WorkingArea'

When using more than one screen:

'Screen.AllScreens'

--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Nov 20 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.