Guest Cretster Posted December 16, 2008 Report Posted December 16, 2008 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
Guest Neobaumuth Posted December 16, 2008 Report Posted December 16, 2008 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.
Guest Cretster Posted December 16, 2008 Report Posted December 16, 2008 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.
Guest pbrand Posted December 16, 2008 Report Posted December 16, 2008 (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 December 16, 2008 by pbrand
Guest Cretster Posted December 16, 2008 Report Posted December 16, 2008 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.
Guest X-Ray A4T Posted December 16, 2008 Report Posted December 16, 2008 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
Guest Paul (MVP) Posted December 16, 2008 Report Posted December 16, 2008 C# or VB.net on the Compact Framework are your best bet! P
Guest JeFK Posted December 16, 2008 Report Posted December 16, 2008 (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 December 16, 2008 by JeFK
Guest Cretster Posted December 16, 2008 Report Posted December 16, 2008 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.
Guest Paul (MVP) Posted December 16, 2008 Report Posted December 16, 2008 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
Guest JeFK Posted December 16, 2008 Report Posted December 16, 2008 (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 December 16, 2008 by JeFK
Guest JeFK Posted December 16, 2008 Report Posted December 16, 2008 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
Guest Paul (MVP) Posted December 16, 2008 Report Posted December 16, 2008 You can full screen by setting form to maximized IIRC. re: G-Sensors, check here: latest version of API for HTC and Omnia: http://www.koushikdutta.com/2008/10/using-...etergsenso.html P
Guest Cretster Posted December 16, 2008 Report Posted December 16, 2008 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.
Guest X-Ray A4T Posted December 17, 2008 Report Posted December 17, 2008 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.
Guest pbrand Posted December 17, 2008 Report Posted December 17, 2008 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.
Guest JeFK Posted December 17, 2008 Report Posted December 17, 2008 (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 December 17, 2008 by JeFK
Guest pbrand Posted December 17, 2008 Report Posted December 17, 2008 (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 December 17, 2008 by pbrand
Guest JeFK Posted December 17, 2008 Report Posted December 17, 2008 (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 December 17, 2008 by JeFK
Guest JeFK Posted December 17, 2008 Report Posted December 17, 2008 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.
Guest JeFK Posted December 18, 2008 Report Posted December 18, 2008 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.
Guest Paul (MVP) Posted December 19, 2008 Report Posted December 19, 2008 You need to copy the file to the device, in the same directory as the EXE perhaps? P
Guest Paul (MVP) Posted December 19, 2008 Report Posted December 19, 2008 That's fine, you can add them to the CAB no problem. P
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now