Page 1 of 1

Check for screen size. Is possible?

Posted: Tue Feb 24, 2009 12:31 pm
by xVar
Hi everybody!

I make my "first aplication", and probe run on PC device.
All work.

But my device have screen lager than device emulator, and some controls like smaller.
For example browse control have white area on bottom of screen.
Can I test my device for screen size in any way?

Regards.
Andrej.

Re: Check for screen size. Is possible?

Posted: Tue Feb 24, 2009 12:58 pm
by Antonio Linares
Andrej,

Please try these values:

GetSysMetrics( 0 )
GetSysMetrics( 1 )

Re: Check for screen size. Is possible?

Posted: Wed Feb 25, 2009 7:44 am
by xVar
Thanks!

I wil try this.

Regards.

Andrej.

Re: Check for screen size. Is possible?

Posted: Thu Feb 26, 2009 7:41 am
by xVar
It's work.

But system tray in WinCE 5 is smaller than system tray in lastest versions of WinCE.
Can I check for OS version ?

Regards.
Andrej

Re: Check for screen size. Is possible?

Posted: Thu Feb 26, 2009 11:07 am
by Antonio Linares
Andrej,

Code: Select all

#include "FWCE.ch"

function Main()

   local oWnd
   
   DEFINE WINDOW oWnd TITLE "Version"
   
   @ 9, 2 BUTTON "Version" ;
      SIZE 210, 30 ACTION ShowVersion()

   ACTIVATE WINDOW oWnd
   
return nil   

function ShowVersion()

   local aVersion := GetVersion()
   
   MsgInfo( Str( aVersion[ 1 ] ) )
   MsgInfo( Str( aVersion[ 2 ] ) )
   MsgInfo( Str( aVersion[ 3 ] ) )
   MsgInfo( Str( aVersion[ 4 ] ) )
   
return nil            
 

Re: Check for screen size. Is possible?

Posted: Thu Feb 26, 2009 11:13 am
by xVar
Thanks Antonio!
Saludos :)
Andrej.