• Announcements

    • Reminder - MoDaCo position on illegal content   07/30/15

      ILLEGAL CONTENT I'd like to just reaffirm MoDaCo's position regarding piracy and illegal content in the light of some recent questions / postings. Posts will be censored by myself or my moderation team if the contain or link to: Illegal / pirated / cracked software or sites that host such softwareNintendo emulators / ROMs or sites hosting them (in light of Nintendo's legal stance)CUSTOM ROMS You may discuss and post links to custom device ROMs on MoDaCo, provided the following rules are adhered to: ROMs must not contain any illegal 3rd party software (this includes trial versions included without permission)ROMs must give full credit to the original authorISSUES If you have any issues with this policy, please contact PaulOBrien directly via PM.
    • Reminder: Selling items on the forum directly is not allowed   07/30/15

      Please note that selling items on the forum directly is not allowed by the forum rules. There is a forum for eBay auctions whereby you can list the items on eBay and link to them there. This is the ONLY forum for this type of activity. You may also advertise links to the eBay forum in your signature. Please note that selling directly in contravention of these rules will result in a warning / suspension / ban.
Sign in to follow this  
Followers 0

Programming WinMo - which language to begin with?

24 posts in this topic

Posted

Hi guys

I'd like to be able to start tinkering with writing small apps for Windows Mobile as I'm enjoying the omnia so much and generally buy winmo phones anyway.

I am already a programmer by trade although currently only have a few years experience in one object orientated language called Graphtalk.

From you folks that are already doing this stuff, I'd be interested to hear what the favoured languages would be for writing winmo apps, and any particularly good resources you've found, in particular if you have only recently started or are self learned etc.

I'm guessing the favoured ones will be Java or C# and I have no experience of these at present but would quite like to start dabbling.

All sensible suggestions gratefully received, cheers :rolleyes:

Jim

0

Share this post


Link to post
Share on other sites

Posted

Hi guys

I'd like to be able to start tinkering with writing small apps for Windows Mobile as I'm enjoying the omnia so much and generally buy winmo phones anyway.

I am already a programmer by trade although currently only have a few years experience in one object orientated language called Graphtalk.

From you folks that are already doing this stuff, I'd be interested to hear what the favoured languages would be for writing winmo apps, and any particularly good resources you've found, in particular if you have only recently started or are self learned etc.

I'm guessing the favoured ones will be Java or C# and I have no experience of these at present but would quite like to start dabbling.

All sensible suggestions gratefully received, cheers :rolleyes:

Jim

I think the best way is using C++ with Visual C++ from Microsoft. It allows you to save thousand lines of code with MFC programming and the API.

0

Share this post


Link to post
Share on other sites

Posted

Really? C++ is another one I do not know but I'd read it's not an ideal point for starting off and that it's more complex to learn than others I'd mentioned.

Don't shoot me if that's not true - it's simply what I've read on other sites where I've been looking into this sort of thing.

0

Share this post


Link to post
Share on other sites

Posted (edited)

Really? C++ is another one I do not know but I'd read it's not an ideal point for starting off and that it's more complex to learn than others I'd mentioned.

Don't shoot me if that's not true - it's simply what I've read on other sites where I've been looking into this sort of thing.

Luckily there's no need to use C++ whatsoever. Simple use the dotnet compact framework (2.0 or 3.5) and there are no hassles with MFC et al.

You can develop in Visual Basic or C# whatever you like. You can use Visual Studio or an open source tool like SharpDevelop. Or you can use a cheap solution like Basic4PPC which is a basic dialect.

Edited by pbrand
0

Share this post


Link to post
Share on other sites

Posted

Thanks for the suggestions - I'll do some googling later on them.

Are there advantages to using one language over another, or do certain languages lend themselves to certain kinds of apps in any way for instance?

I've read that Python is a very fast one to get stuck into and get results with, and that it's fairly simple to learn.

0

Share this post


Link to post
Share on other sites

Posted

Hi,

having been a C# programmer, developing in .net compact framework is really simple. What I did while writing a simple Sudoku for myself as I don't like any of the commercial ones was to build a windows application and once that was working with a form the size of the Omnia screen was to convert it to a compact WM app (mainly copy and paste). I even have simple code to handle the screen rotation. I know there is a free personal edition of Visual Studio you can download but I don't know if it supports compact framework.

Ray

0

Share this post


Link to post
Share on other sites

Posted

C# or VB.net on the Compact Framework are your best bet!

P

0

Share this post


Link to post
Share on other sites

Posted (edited)

C# or managed c++ (.net).

Does anybody know which function do i have to use to check the screen orientation (C#)?

I didn't find any funtion to do that or to rotate screen.

I have to make a button (event) to rotate it.

Edited by JeFK
0

Share this post


Link to post
Share on other sites

Posted

Thanks very much for the replies chaps.

I think I will start looking at C# then (like I have time!). Aside from anything else, it wouldn't hurt to know another language at work, but this is more for fun than anything.

I understand the free (Express) studio does not allow dev for WM, but that a lot of it is similar. I'll have to investigate therefore exactly what I need in terms of software requirements in order to get started.

0

Share this post


Link to post
Share on other sites

Posted

JeFK - you can get the screen orientation by reading Microsoft.WindowsCE.SystemSettings.ScreenOrientation, or in more default by getting the bounds of the primaryscreen.

To rotate the screen use Microsoft.WindowsCE.SystemSettings.ScreenOrientation = ScreenOrientation.Angle90 or Microsoft.WindowsCE.SystemSettings.ScreenOrientation = ScreenOrientation.Angle0.

Cretster, sadly the Express editions don't support mobile development (despite me beating on MS and even having an email exchange with Steve Ballmer and then a VS program manager he nominated), but I am hopeful they'll come to their sense in the future.

All you need is VS2005 Standard or VS2008 Pro (not free), the WM SDK (free) and ActiveSync / WMDC (free).

P

0

Share this post


Link to post
Share on other sites

Posted (edited)

JeFK - you can get the screen orientation by reading Microsoft.WindowsCE.SystemSettings.ScreenOrientation, or in more default by getting the bounds of the primaryscreen.

To rotate the screen use Microsoft.WindowsCE.SystemSettings.ScreenOrientation = ScreenOrientation.Angle90 or Microsoft.WindowsCE.SystemSettings.ScreenOrientation = ScreenOrientation.Angle0.

Cretster, sadly the Express editions don't support mobile development (despite me beating on MS and even having an email exchange with Steve Ballmer and then a VS program manager he nominated), but I am hopeful they'll come to their sense in the future.

All you need is VS2005 Standard or VS2008 Pro (not free), the WM SDK (free) and ActiveSync / WMDC (free).

P

YESS, you are the man. Thanks

Edited by JeFK
0

Share this post


Link to post
Share on other sites

Posted

*bows*

:rolleyes:

P

0

Share this post


Link to post
Share on other sites

Posted

What about full screen? I'd like to have a full screen app. Do you know how can i "read" from g-sensors? Like if i'd like to write a pong game which would be controlled by moving phone.

That would be all.

Manny thanks for your help

0

Share this post


Link to post
Share on other sites

Posted

Thanks for the info Paul - very useful.

Excuse my ignorance here, but what is the SDK needed for with regards to this? I take it there are elements that are not catered for by say VS2005 alone, but I thought that was a complete development package for a few different languages.

0

Share this post


Link to post
Share on other sites

Posted

The SDK lets You build mobile apps in almost the same way as windows apps. By default Visual Studio does not include the things you need to build mobile apps as most people do not need to build mobile apps. The SDK adds this functionality.

0

Share this post


Link to post
Share on other sites

Posted

I understand the free (Express) studio does not allow dev for WM, but that a lot of it is similar. I'll have to investigate therefore exactly what I need in terms of software requirements in order to get started.

You could look at SharpDevelop which I mentioned. I don't use it myself but have heard good stories about it. And it does support for WM development.

0

Share this post


Link to post
Share on other sites

Posted (edited)

I'd like to play a sound when a button is pressed. So i have an event and inialized soundplayer

System.Media.SoundPlayer player = new System.Media.SoundPlayer();

string path="c://a.wav";

player.SoundLocation = path;

player.Load();

player.Play();

I tryed all possibillitys with path but i always get an error when the app came to this part of code.

"

An unhandled exception of type 'System.IO.FileNotFoundException' occurred in System.dll

Additional information: Could not find file '\c:\a.wav'.

"

What's wrong. What path should i write. File is located in c:\, in project dir,...

Edited by JeFK
0

Share this post


Link to post
Share on other sites

Posted (edited)

string path="c://a.wav";

Although it's windows, sort of, I think WM does not know of a c: drive :rolleyes:

Have you tried

string path=@"\a.wav";

?

Edited by pbrand
0

Share this post


Link to post
Share on other sites

Posted (edited)

Although it's windows, sort of, I think WM does not know of a c: drive :rolleyes:

Have you tried

string path=@"\a.wav";

?

No, i tryed

player.SoundLocation = @"a.wav";

but i still get an error. App is looking for a file in \a.wav which I think it is a root dir of the device.

I'd like to put some files into dir sounds in the same folder that exe file is.

Although it's windows, sort of, I think WM does not know of a c: drive :)

I have picture for a background and i also added it like d:\pictures\image.jpg..but in this case it works

Edited by JeFK
0

Share this post


Link to post
Share on other sites

Posted

Ok! I found out that if i make path "\a.wav", I have to copy this file into the root dir of device. Then it works. But i like to

include those wavs into cab...so the location of wavs depends on path that user specified.

0

Share this post


Link to post
Share on other sites

Posted

I have one more question!

I'd like to make an invisible slider which would recognise moving finger from top-bottom or bottom top. I would like to track finger touch like lock/unlock slider on iphone.

0

Share this post


Link to post
Share on other sites

Posted

You need to copy the file to the device, in the same directory as the EXE perhaps?

P

0

Share this post


Link to post
Share on other sites

Posted

That's fine, you can add them to the CAB no problem.

P

0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0

MoDaCo is part of the MoDaCo.network, © Paul O'Brien 2002-2015. MoDaCo uses IntelliTxt technology.