Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1715
  • Last Modified:

Convert Windows CE 5 project to Windows Mobile 6 Project in VS2005

I have VS2005 on an XP machine.  I have a VB.NET project that has been running on Windows CE 5 for many years now...  I need to run in on Windows Mobile 6 now.  
I have installed the Windows Mobile 6 Professional SDK, 6.5 DTK and 6.5.3 DTK.  I have rebooted.

If i make a new project, I see Windows Mobile 6 as an option.  However, how can I add WM 6 to the existing project? Can i compile the same code for both devices?  

If I use the Configuration Manager and try to set an active solution platform to WM 6, it does not show up.  if I attempt to make a new active solution platform, WM6 is not available to copy from.

What is the procedure to recompile a project for Windows Mobile 6.x?
Thanks
0
DonnaOsburn
Asked:
DonnaOsburn
  • 6
  • 5
1 Solution
 
alexey_gusevCommented:
have you tried to change the Platform for the project (via Project -> Change Target Platform) ?

if it doesn't work, then you might be required to edit your proj file manually, ie create dummy project for Wm6 and then have a look at something like this:


  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProductVersion>8.0.50727</ProductVersion>
    <SchemaVersion>2.0</SchemaVersion>
    <ProjectGuid>{CC411789-8A77-4B00-A035-6D61982EE85F}</ProjectGuid>
    <OutputType>WinExe</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>YOUR_PROJECT_NAME</RootNamespace>
    <AssemblyName>YOUR_PROJECT_NAME</AssemblyName>
    <ProjectTypeGuids>{4D628B5B-2FBC-4AA6-8C16-197242AEB884};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
    <PlatformFamilyName>PocketPC</PlatformFamilyName>
    <PlatformID>4118C335-430C-497f-BE48-11C3316B135E</PlatformID>
    <OSVersion>5.01</OSVersion>
    <DeployDirSuffix>YOUR_PROJECT_NAME</DeployDirSuffix>
    <TargetFrameworkVersion>v2.0</TargetFrameworkVersion>
    <FormFactorID>
    </FormFactorID>
  </PropertyGroup>

and finally copy it into your old project
0
 
DonnaOsburnAuthor Commented:
The only difference between what you have listed above and my project file is that i have OSVersion 5.02 where yours is 5.01
When i select Project - Change Target Platform - it says the Current Platform is "Windows Mobile 6 Professional SDK".  However, on the configuration manager, Windows Mobile is not an available choice.  If i try to Add a new one, Windows Mobile 6 is not available to copy from.
I notice that the references for my application are all to things like
...Microsoft.WindowsCE.Forms
c:\Program Files\Microsoft Visual Studio 8\SmartDevices\SDK\CompactFramework\2.0\v2.0\WindowsCE\System...., etc
Will i need to change all the references? what would they change too? there is only Compact Framework, PocketPC2003, SDKTools, Smartphone2003, SQL Server, and Visual Studio available under that SDK folder.  Would they have to point to the c:\Program Files\Windows Mobile 6 SDK\???
Donna
0
 
alexey_gusevCommented:
mine was 5.01 because I've used VS2005 and WM50 SDK as an example.

in theory, when you change the platform it would update the references, but that's in theory :)
I usually check where they point to and re-add them manually if needed.

I have tried to create new project (with WM60 already installed though) for WM50, then change target platform, for WinCE50 etc etc

I suspect in your case it might come to the worst case and you'll be needing to recreate the project from scratch. Maybe try to switch to WM50 first and then back to WM6.

"Solution Platforms" is set to "Any CPU" usually so Configuration Manager can't help in this case. Therefore the only thing you should check is that you're using the same CF.NET version (presumably v2.0), then the build for WM50 should work on WM60 (and even for WinCE 5.0)
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
DonnaOsburnAuthor Commented:
I don't have Windows Mobile 5 SDK's installed.  (i went straight to WM 6).
So you are suggesting that i uninstall all the Windows Mobile 6 SDK's DKT's and install the Windows Mobile 5 and try that?
Theory is always great but i've not found Microsoft products to use it much :)
Thanks for your help
Donna
0
 
alexey_gusevCommented:
I completely agree  - MS isn't great at the theory :)

no need to uninstall all SDKs, just install WM50 and try to change the target. sometimes all it takes is a simple step, so having WinCE and then WM50 might do the trick, and then WM6 is likely to reappear too
0
 
DonnaOsburnAuthor Commented:
I have had no luck with this.  It appears WM6 and VS2005 and .Net 3.5 don't want to play nice.  I installed VS2008 and can now at least get my app running on the Unit.  Not working, but running....
 
Thanks
 
0
 
alexey_gusevCommented:
ahhhhhh, you never mentioned cf.net 3.5 (unless I've overlooked it, that is :) )

vs2005 offers cf.net v2.0 as a maximum (regardless of the SDK), for cf.net v3.5 you must have vs2008 standard at least.

what is not working in your project? anything specific?
0
 
DonnaOsburnAuthor Commented:
I have two projects actually.  one is a vb.net (which was the origianla question) and the other is c#.  i'm currently working on the c# one. I was able to get vs2008 to deploy to the device and "run" the app.
what's not working...  Three major issues - after i conquer them, im sure there will be more..
1) I was using wceload.exe to programatically install the cab files in the correct order and check for existing files, etc.  wceload.exe does not appear to exist on WM6.5 Classic device... I can't see if it was replaced with another exe or i have to find a copy that will work...
2) Screen real estate.  on the CE 5 i have great screens with lots of dats, the resolution on this WM6.5 beast shows 4 lines in windows explorer.  same hardware with ce 5 shows 12 lines...  
3) Device Lockdown.  on CE, i could simply force my screen full size and the users could not exit to get to any other app to play (games, ie, whatever)  A requirement...  WM6.5 i haven't figured out how to lock down the title bar with sound, battery, and time. yet...
This is the exact same physical device(Screen size, key configuration, etc).  A Motorola MC3090 (CE 5) vs an MC3190 (WM6.5 Classic with .net 3.5 that comes on it.)
 
 
0
 
alexey_gusevCommented:
1) as far as I know, good old wceload beast is still there, but Classic always had its issues, you might check Security Policies:

http://msdn.microsoft.com/en-us/library/bb416355.aspx
http://msdn.microsoft.com/en-us/library/bb416353.aspx
etc etc

you can examine "HKLM\Security\Policies\Policies" values for a long list of possible settings - there might be few like should cabs be signed or should it prompt for Unknown Publisher and so forth

2) it depends on the device you're using, WM 6.x Professional devices have huge screens with the resolutions like 600x800; Classic edition is just a humble phone :)...

3) I would recommend the simplest method to get full screen forms:

- don't use any frame for the form
- set its window state as maximized

it's not ideal, in theory you should P/Invoke WIn32 API SHFullScreen() with different flags, but in most scenarios it might just do
0
 
alexey_gusevCommented:
I think the question is worth keeping (let alone award some points :) ) because it highlights potential caveats in conversion and also what to specify when asking such kind of question (targeting cf.net 3.5 for instance - it was crucial for the result since vs2005 doesn't support it)
0
 
DonnaOsburnAuthor Commented:
I thank you for all your assistance on this.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 6
  • 5
Tackle projects and never again get stuck behind a technical roadblock.
Join Now