PDA

Click to See Complete Forum and Search --> : getting screen resolution?


carloscamoes
Nov 14th, 1999, 06:19 AM
How can i get the current screen resolution in VB 6?
Do i need to call an API function?
If so, what is it and how is declared and used?

Thanks.

Aaron Young
Nov 14th, 1999, 06:30 AM
Try:

Private Sub Command1_Click()
With Screen
MsgBox (.Width / .TwipsPerPixelX) & "x" & (.Height / .TwipsPerPixelY)
End With
End Sub



------------------
Aaron Young
Analyst Programmer
aarony@redwingsoftware.com
adyoung@win.bright.net