Forms for both Windows Mobile and WIN32 platforms

G

Guest

Hi All,

We are trying to develop an application to be run primarily on Windows
Mobile Devices but also on WIN32 based platforms as well.

We are just wondering if there is any way to make our forms that we design
for Windows Mobile devices scale to the screen size of any WIN32 platforms
that the application is run on. At the moment, they display when run on a
WIN32 platform, but the forms only appear at the size they were created (ie.
screen size of a PDA).

I briefly looked at the TableLayoutPanel class, but I couldn't see how to
add that to my project (it doesn't appear on my Toolbox). It may be that it
isn't available for projects with a target device of Windows Mobile or Pocket
PC. Also, I came across a MSDN article that says to use this sparingly for
performance reasons. What alternatives are there? Just handling the forms
resize event and resizing components accordingly?

Any help is appreciated.

Thanks,
Chris
 
D

Daniel Moth

performance reasons. What alternatives are there? Just handling the forms
resize event and resizing components accordingly?
Yes, combined with docking and anchoring.

Having said that, I would question the design that mandates to reuse forms
on both platforms (unless maybe if the win32 platform is a small UMPC or
other such smallish touch screen device). Just reuse the business logic and
wrap it with platform-specific GUIs. My £0.02.

http://msdn.microsoft.com/msdnmag/issues/07/07/ShareCode/default.aspx

Cheers
Daniel
 
G

Guest

I agree with Daniel that this would not be the best possible solution, but
you could use System.Windows.Forms.Screen.PrimaryScreen in your Constructor
of your forms to set the form size. This gives you the Primary Screen
display area excluding task bars and menus.

Good Luck,
Rick D.
Contractor
 
G

Guest

Hi Daniel and Rick,

Thanks for your responses.

Thanks also for pointing me towards your article too Daniel. That looks like
it will be a great resource for our development team. Unfortunately, we are
all new to .NET and C# and are therefore going to have quite a steep learning
curve.

I realise that what I am requesting is not a ideal way to go, but it is
merely something we are looking at to provide functionality on both platforms
with minimal effort upfront. The reason being is that our project has a fixed
deadline, and we have LOADS to do in that time.

Having said that, we are trying to design the app in such a way that we are
totally abstracting the UI from the rest of the business logic code and at a
later stage we could look at writing a different UI for Desktop/Tablet PCs.

I can see I will be using this forum a lot over the next couple of months :)
Please forgive me if I ask seemingly stupid questions...I will get there in
the end.

Thanks again,
Chris
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top