********************************调整解析度*************
Local OldHeight,OldWidth,ChangeHeight,ChangeWidth
OldHeight=600
OldWidth =800
ChangeHeight=0
ChangeWidth=0
IF SYSMETRIC(1)#OldWidth
THISFORM.Lockscreen=.F. &&详情查阅LockScreen属性
ChangeHeight=Sysmetric(2)/OldHeight
ChangeWidth=Sysmetric(1)/OldWidth
**变动表单外框
IF This.BaseClass='Form'
WITH THIS
.Height=.Height*ChangeHeight
.Width =.Width*ChangeWidth
.Top
=.Top*ChangeHeight
.Left
=.Left*ChangeWidth
ENDWITH
ENDIF
**变动表单内所有控件的大小和位置
FOR
I =1 TO
This.ControlCount
WITH THIS.Controls(I)
.Height=.Height*ChangeHeight
.Width =.Width*ChangeWidth
.Top
=.Top*ChangeHeight
.Left
=.Left*ChangeWidth
ENDWITH
ENDFOR
Thisform.Lockscreen=.F.
ENDIF
THISFORM.REFRESH
********调整解析度结束*****************************