Cannot get Device ID on Pocket PC 4.2

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have been using the code posted on http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetcomp/html/retrievedeviceid.asp to get the device ID on Pocket PC 3.0 devices, and it is working well. However, this code does not work on devices which are running the 4.2 OS.

Anybody knows how to get the device ID on Pocket PC 4.2?

The failure mode on the 4.2 devices is that the KernelIoControl call always returns a status of ERROR_INSUFFICIENT_BUFFER. It tells you that the required buffer size is 36, but gives this error even when the buffer size is set to 36. The only time is returns success is when the buffer size is set to 16. But then it returns a buffer that does not contains the correct information.

Thanks,
Joseph Kliger
 
Magnus,
Thank you for your answer to my post. However, the code you sent did not get through. Can you please send it directly to me at (e-mail address removed)?

Thanks,

- Joseph Kliger
 
Back
Top