Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How do I get available _screen.Height/Width ?
Message
From
21/07/2002 05:08:03
 
 
To
20/07/2002 23:10:10
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00680835
Message ID:
00680861
Views:
16
>If I set _Screen.ActiveForm.Height = _Screen.Height and _Screen.ActiveForm.AutoCenter=.T. the top of the form is hidden and _Screen.ActiveForm.Top show -35 (different for different screen resolutions).
>
>How can I find the available height of the _Screen so I can prevent this?
>
>TIA

Bill,

see if this gets you any further (Vfp6 SP3)
_Screen.ActiveForm.Top shows -4 over here. I still see the form caption
#define	FORMCAPTIONHEIGHT	;
	iif(empty(obj.TitleBar), ;
			0, ;
			iif(obj.HalfHeightCaption, ;
				sysmetric(SYSMETRIC_HALFHEIGHTBUTTONHEIGHT), ;
				sysmetric(SYSMETRIC_WINDOWTITLEHEIGHT) ;
			) ;
		)

local obj
obj = _Screen.ActiveForm

local _height, _width
if( obj.Desktop or obj.ShowWindow = 2 )
	_height = sysmetric(22) 
	_width = sysmetric(21)
else
	_height = _screen.Height
	_width = _screen.Width 
endif
_height = _Height - FORMCAPTIONHEIGHT
obj.Height = _height
obj.AutoCenter = .T.
Gregory
Previous
Reply
Map
View

Click here to load this message in the networking platform