Orientation Aware Control and Smartphone

Topics: Mobile Client Software Factory
Aug 10, 2006 at 1:26 AM
originally posted by: thaoula1

Hi Guys,

Is there anyway that you get the orientation aware control to detect the platform it is running on.

What i would like to do is build an application that will run on both the smartphone and pocket pc using the same binary.

I would like to be able to set the position of controls based on platform and resolution. Most new smartphones now use the same resolution as pocket pc but the ui is laid out differently. ie Smartphone places labels on top of textboxes whilst pocket pc places labels to the left or right of textboxes.

It would be great to be able to select the platform and the resolution. This way we can build single handed applications that dont use controls not available on both platforms.

Kind Regards,
Tarek
Aug 10, 2006 at 2:19 AM
originally posted by: dcazzulino

The problem is that within Visual Studio, you have to select the target platform for a project, and you cannot target two platforms simultaneously with the same project.
Aug 10, 2006 at 3:05 AM
originally posted by: thaoula1

Hi dcazzulino,

The executable will run just fine if you avoid using controls that are not available on both platforms.

I was wondering if you could get the installed SDK's and screen resolutions from the registry. Then you would have a property called Platform = Smartphone or Pocket PC and a property called screen resolution.

In WM5 a great deal of emphasis was placed on single handed device use as can be seen in Pocket Outlook. An application that is designed to using a single hand would be able to run fine on both the smartphone and pocket pc.

This is just a thought, i will try and alter the control myself and test out the theory.

Kind Regards,
Tarek
Aug 10, 2006 at 3:39 AM
originally posted by: dcazzulino

Probably you won't need to talk to the registry. There's an IPlatformInformation service that may contain that information.