![]() |
|
|||||||
| Home | Register | FAQ | Members List | Search | Today's Posts | Mark Forums Read |
| Questions & Help Needed Post any question regarding Basic4ppc. |
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
||||
|
Hi Robert,
I was wanting this functionality as well. It seemed like a good time to create my first library, and here it is ![]() The zip file includes the dll, a B4PPC test project, and the VB.NET source. bDeviceInfo.GetOSVersionString returns the OS name and version number as a string. Let me know if you need to get access to just the version as integer; it would not be hard to add. bDeviceInfo.GetDisplayWidth returns screen width as integer bDeviceInfo.GetDisplayheight returns screen height as integer Let me know what you think of this. Best wishes,
__________________
Brian Rathbone Laptop: AMD Turion 64 Mobile 2ghz, 2GB RAM, Dual GeForce Go 7900 GTX 768MB SLI, Dual 200GB HDD at RAID0. XP Pro sp2 Device: Treo 750, WM6, 300mhz,128MB RAM, 2GB miniSD, 240x240 display |
|
||||
|
Hi Brian,
I'm speechless, a library in response. The device, an iPAQ hx210 comes up with these responses: GetOSVersionString: Microsoft Windows CE 5.2.1711. It is supposed to be WM 6, but I assume that is Microsoft's nomenclature for WM6(?) GetDisplayWidth/Height: In an application compiled w/o optimization the result is 240x320 (the form dims), although the physical resolution is VGA. Is there any means of quering the LCD dimensions? Anyway, your approch is awesome. Thanks so much! Robert |
|
||||
|
Hi Robert,
I was hoping for better results with the screen size, but I'll see if I can find another way to get the actual screen size. Regarding the OS Version, I found this list on MSDN: Platform Release Windows CE kernel version Windows Mobile 6 5.2 Wndows Mobile 5.0 5.1 Windows Mobile 2003 SE 4.21 I think I will add access to MajorVersion and MinorVersion from the library, that way you can detect the OS version without having to parse the OS Version string. That way we can say if MajorVersion = 5 and MinorVersion = 2 then we are on WM6 ![]() I'll probably get a chance to look at this later tonight. Until then . . . All the best,
__________________
Brian Rathbone Laptop: AMD Turion 64 Mobile 2ghz, 2GB RAM, Dual GeForce Go 7900 GTX 768MB SLI, Dual 200GB HDD at RAID0. XP Pro sp2 Device: Treo 750, WM6, 300mhz,128MB RAM, 2GB miniSD, 240x240 display |
|
||||
|
Hi Brian,
I thought it might be difficult to retrieve LCD pixel array dimensions. Unfortunately, I can't assist without having VS, but I feel you are on the right way towards a solution ![]() Regarding the o/s version, I believe your current method is great. Parsing is no big issue, it is as simple as this: If StrIndexOf(bDeviceInfo.GetOSVersionString,"5.2",0) > -1 Then WM6 Perhaps something like bDeviceInfo.GetOSVersionCode which returns 0, 1 or 2, respectively, would be nice but only if it is not too much trouble. Thank you so much! Robert |
|
|||
|
Hello Brian
Your dll is just what I need - and it works a treat ... Am I OK to use in my freeware game I am making? (Its goind to be released in May ...) I will whack you in my credits also if its OK with you. Many thanks Steve |
|
||||
|
Hi Steve,
Thanks for checking, but you can use the dll and source in any way you like. As far as I'm concerned, it's in the public domain. Just a little gift to the community. I wouldn't object to the credit, just don't feel obligated in any way .I'd still like to figure out Robert's VGA question and post a new version, but my workload has been a bit overwhelming lately. Hopefully I'll get back to it soon. Anyway . . . I'm glad you found it helpful. All the best, Brian P.S. good luck with the game, I look forward to checking it out.
__________________
Brian Rathbone Laptop: AMD Turion 64 Mobile 2ghz, 2GB RAM, Dual GeForce Go 7900 GTX 768MB SLI, Dual 200GB HDD at RAID0. XP Pro sp2 Device: Treo 750, WM6, 300mhz,128MB RAM, 2GB miniSD, 240x240 display |
|
|||
|
Thanks Brian.
Alfcen, referring to your earlier pseudocode, in the interim, perhaps also put a space character preceding the 5.2 as follows: Quote:
An interesting link for win pda versions can be found at http://www.pocketpcfaq.com/wce/versions.htm and ... http://pocketpccentral.net/help/which_version_wm.htm I have access to VS.NET at work. When I have time I really must take a look at it ... I think this is my next step forward in programming ... we've had it for a couple of years now but been tied up at work with introducing HP Openview and "ITIL Change management" (boring bits)for the past year or so, plus developing ASP web front end interfaces (exciting bits) for Openview. Last edited by badkarma : 04-12-2008 at 09:35 AM. |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Would like some more info | Mr_Gee | Questions & Help Needed | 5 | 02-26-2008 06:01 AM |
| incorrect results on screen size 480x272 | gs4322 | Questions & Help Needed | 5 | 01-15-2008 05:40 PM |
| FullScreen and getting screen size | glook | Questions & Help Needed | 5 | 11-23-2007 07:48 PM |
| screen size to form size relation | Cableguy | Basic4ppc Wishlist | 2 | 08-14-2007 10:40 PM |
| screen size on desktop | Cableguy | Questions & Help Needed | 3 | 07-02-2007 05:57 PM |