Link to home
Start Free TrialLog in
Avatar of manishverma77
manishverma77

asked on

resolution problem in 17 inch monitor

dear friends
i have a problem regarding resolution of the screen.i have make a project .when i install it in 15 inch moniter then it works fine means all the form element are in fixed position.but when i install it in 17 inch monitor then form lay out is compress.
i want when i install it on 17 inch moniter then form covered the monitor and its element placed well manner position.
plz give me coding about this
regard
manish
Avatar of EDDYKT
EDDYKT
Flag of Canada image

If you use the same resolution, then I don't see how does it happens

I don't quite understand your question
Hi,
  See if this helpsOption Explicit

Private Declare Function SystemParametersInfo Lib "user32" Alias "SystemParametersInfoA" (ByVal uAction As Long, ByVal uParam As Long, ByRef lpvParam As Any, ByVal fuWinIni As Long) As Long
Private Const SPI_GETWORKAREA = 48
Private Type RECT
    Left As Long
    Top As Long
    Right As Long
    Bottom As Long
End Type
Private rc As RECT

Private Sub Form_Load()
SystemParametersInfo SPI_GETWORKAREA, vbNull, rc, 0
    Me.Move rc.Left * Screen.TwipsPerPixelX, rc.Top * _
            Screen.TwipsPerPixelY, rc.Right * _
            Screen.TwipsPerPixelX, rc.Bottom * _
            Screen.TwipsPerPixelY
End Sub


This is routine to be there in every form

Avatar of DanRollins
Moderator, my recommended disposition is:

    Save as PAQ -- No Refund.

Dan Rollins -- EE database cleanup volunteer
ASKER CERTIFIED SOLUTION
Avatar of CetusMOD
CetusMOD
Flag of Netherlands image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial