Identifying XPe from XP in a VC++ application

  • Thread starter Thread starter Prasoon
  • Start date Start date
P

Prasoon

We have a VC++ application which will be run on both desktops and
Embedded devices.

Now, for XPe, is there a registry key which would tell for sure that
the Operation System is Windows XP Embedded and not Windows XP
Professional. It'd be easier to control the application from that
point if the OS is verified since we have different behavior for
Embedded Devices and Normal Desktops.

Thanks
 
Hi Prasoon,

There're a lot of solutions to tell XPE and XP Pro. I think the easier way
is to find "HKLM\system\FBA" exists or not, if yes, it is XPE.

Regards,
Ethan Chen
Advantech Co., Ltd.
Microsoft eMVP
 
Dear Prasoon,

Please try following 2 ways.
1. Call API

BOOL GetVersionEx(

LPOSVERSIONINFO lpVersionInfo

);



OSVERSIONINFOEX structure (which is the output of this call)

One of the members is wSuiteMask (a WORD variable).

Check the VER_SUITE_EMBEDDEDNT (0x00000040) flag in this variable.



2. Query value in Registry


[HKEY_LOCAL_MACHINE\SYSTEM\Cur-rentControlSet\Control\Product-Options]

Key Name: ProductSuite

Type: MULTI_SZ

Value: EmbeddedNT

(In XP Pro, it seems that no content in this key)


--
Best Regards,
Bing Chen
Advantech Co., Ltd.
Microsoft eMVP

?? - ???????????????
http://www.advantech.com.tw/epc/newsletter/ATW/2005MS/
 
Back
Top