Working with screen resolutions

Discussion in 'Questions (Windows Mobile)' started by Nycran, Nov 6, 2007.

  1. Nycran

    Nycran Member Licensed User


    Hi all, just wondering if some experienced PPC developers can shed some light on screen resolutions?

    I have a Dell AXIM X51v, and the first app I compiled and tested appeared in a very small section of the screen. So, I adjusted the screen size to 480 x 640, and it looked much better. However, this has some other problems:

    A) The SIP line is no longer accurate, as the SIP comes up over the top of the bottom of the screen.

    B) Does this mean I have to create multiple versions of the app, so I can support different screen resolutions?

    Any advice would be gratefully received.

  2. Erel

    Erel Administrator Staff Member Licensed User

    How did you change the screen size?
    The settings on the desktop IDE only affect desktop applications.
    High resolution screens use double pixeling method to stretch the form to the whole screen.
  3. Nycran

    Nycran Member Licensed User

    Thanks for your help Erel.

    It's really strange though as I'm definitely seeing the IDE setting impact the device screen size. For example, if I change the screen size in the IDE back to 240 x 320 by selecting Tools --> Screensize (from the designer window), and then if I recompile the app for Device.exe, the controls appear very small. Moreover, the default screen size is appearing really tiny on the Axim.

    I don't know if the way I'm installing it is making a difference... because I'm using Vista (no activesync), I'm copying across the ARMV4 Cab file directly to the device and then running it on the device - this installs the application.

    Any thoughts?
  4. Erel

    Erel Administrator Staff Member Licensed User

    How do you see Basic4ppc IDE on the device?
  5. Nycran

    Nycran Member Licensed User

    I'm using the IDE only on the desktop at the moment. I compile on the desktop, and then copy the CAB to the PPC using the Windows file explorer. Should I be trying the IDE on the PPC device?
  6. Erel

    Erel Administrator Staff Member Licensed User

    Just to test if it shows correctly or not.
    It will help me understand the problem.
  7. Nycran

    Nycran Member Licensed User

    Actually, that in itself is a problem. When I run the setup program to install the device IDE, it fails because ActiveSync is not installed (I can't install ActiveSync on Vista I don't think). Is there a CAB download for the IDE? Should I be using Basic4PPC on a non-vista PC?
    Last edited: Nov 6, 2007
  8. agraham

    agraham Expert Licensed User

  9. Erel

    Erel Administrator Staff Member Licensed User

    If you don't succeed, send me an email to and I'll send you the Cab file.
  10. Nycran

    Nycran Member Licensed User

    Thanks for that guys. I installed the Windows Mobile Center 6 software and now I can install programs onto the device.


    Ok, moving on. The IDE on the device works fine, and if I write a new test application on the device then the form appears as you would expect. I dragged a button and a list box onto a new form, and checked the width of the listbox which was about 200px.

    So, it seems my problem only occurs when I make an application via the desktop IDE.

    To confirm the issue, I made a brand new application using the desktop that simply had a button and a listbox. I've attached a couple of screenshots to this post.

    Designer.jpg is the design of the form on the desktop. form_on_axim.jpg is a screen shot taken on the device itself.. you can see how the controls are almost half the size they should be.

    Hope that helps.

    Attached Files:

  11. agraham

    agraham Expert Licensed User

    It looks like your Axim thinks that the compiled exes are HI_RES_AWARE. - note the large button text. You haven't used a hack to get normal QVGA programs to run non-pixel doubled have you?

    Have you seen this thread. It doesn't help your immediate problem but it might be of interest once you have.
  12. Nycran

    Nycran Member Licensed User

    Nope, I didn't use any hacks. I just compiled normally, used CabWiz to pack the exe and SQLite dll's into an installer and then installed it on the device. Are there any config files perhaps that I need to include in the Cab? Are there any files I should look for in my application direction? Not sure how to solve this.
  13. Erel

    Erel Administrator Staff Member Licensed User

    I don't see this behavior here.
    Do other users with VGA devices see this misaligned screen?
  14. Nycran

    Nycran Member Licensed User

    Hi Erel, don't mean to be a pain here, but just wondering if you could investigate this further, as in order to support the Axim X51v (and probably other VGA PDAs), I'm going to need to make two versions, which I'd prefer not to have to do.

    I'm developing on the desktop, so having the problem go away when I compile it on the device itself isn't going to help me much.

    Do you have any suggestions for what I can try to resolve this? Does anyone else here actually have an X51v?
  15. Erel

    Erel Administrator Staff Member Licensed User

    I haven't tested it with an Axim X51v but other VGA devices do show the screen as 240x320 (double pixels).
    @RandomCoder, do you have this problem with your Axim X51v?
  16. Nycran

    Nycran Member Licensed User

    Thanks Erel. If it comes down to it, I'll send you my Axim for testing and some money so you can send it back again.
  17. Erel

    Erel Administrator Staff Member Licensed User

    Lets try a simple workaround:
    Sub Globals
    'Declare the global variables here.
        Dim controls(0)
    End Sub

    Sub App_Start
    If Form1.Width > 400 Then
    controls() = GetControls("Form1")
    For i = 0 To ArrayLen(controls())-1
                name = 
    Control(name).Top = 2 * Control(name).Top
    Control(name).Left = 2 * Control(name).Left
    Control(name).Width = 2 * Control(name).Width
    Control(name).Height = 2 * Control(name).Height
    Control(name).FontSize = 2 * Control(name).FontSize
    End If
    End Sub
  18. RandomCoder

    RandomCoder Well-Known Member Licensed User

    I've created a Form with a Button and Listbox as shown in Nycran's screenshot then transferred it using Window Explorer and it's displayed exactly as it was on the Desktop IDE.

    I've had a look at the system settings of my Axim X51v and nothing seems to affect the size of the controls on the Form.
    On the device I have WM5 and on my desktop I have XP Media Center.

    The only problem I've ever experienced is that font size is displayed slightly larger on the desktop than on the device, but I'm pretty sure this is covered elsewhere in the forum and is to do with the Device fonts being different to the Desktop.

  19. Erel

    Erel Administrator Staff Member Licensed User

    Thank you for your help RandomCoder.
  20. RandomCoder

    RandomCoder Well-Known Member Licensed User

    The only suggestion I can offer is that Nycran hard resets his device and then installs B4PPC and .Net Framework to see if the problem still exists.
    Hopefully that should work. He will then need to re-install all his other app's (one at a time obviously) and see if the problem returns.

    It's a pain, but reverting the device back to factory default should work :sign0013:

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice