Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Screen Resolution Checking?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00468734
Message ID:
00468739
Vues:
24
Here's how I do that.
	*********************************************************
	** Check screen resolution.  Can't run well in less than
	** 800 x 600.
	** Make sure the screen is in at least 800 x 600 mode.
	DECLARE INTEGER GetSystemMetrics IN Win32API;
	  INTEGER nIndex
	* SystemMetrics(1) returns height, (0) returns width.
	IF GetSystemMetrics(1) < 600

		nResponse = MESSAGEBOX( cProgram + " has been optimized to run at 800 x 600 resolution." + chr(13) +;
					" If you run it with a lower resolution, navigation will be difficult." + chr(13) + ;
					chr(13) + " Would you like to change the resolution now?",  52, cWindowName )
		** 6 = Yes was clicked
		IF nResponse = 6
			** This fires the Display settings and opens it to the
			** resolution tab.
			RUN /N rundll32.exe shell32.dll,Control_RunDLL DESK.CPL,@0,3
		ENDIF &&nResponse = 6
	ENDIF &&GetSystemMetrics(1) < 600
	*********************************************************
Marty Smith, CSQE
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform