all groups > dotnet compact framework > january 2007 >
You're in the

dotnet compact framework

group:

Eletronic Serial Number


Eletronic Serial Number mmuzilli NO[at]SPAM gmail.com
1/12/2007 6:05:02 AM
dotnet compact framework:
Howdy all,

I'd like to know how can I get the Eletronic Serial Number of my
handheld. Which API do I have to access?

I'm developing using MS VS2003 C# (Compact FrameWork) for a Intermec
CN3 handheld. I don't know if I can access via Windows API or if I have
to access using Intermec API.

Can you please help me?

Thank you in advance,

Marcelo Muzilli
Re: Eletronic Serial Number Paul G. Tobey [eMVP]
1/12/2007 9:12:59 AM
There is not necessarily any such thing, so there's no API to access it. If
you are sure that the vendor of your device stamps each one electronically,
ask them what API they can provide.

Paul T.

[quoted text, click to view]

Re: Eletronic Serial Number Arun
1/12/2007 9:59:53 AM
I think there is an unmanaged dll "psuuid0c.dll" from Intermec SDK
which you need to P/Invoke and call GetSerialNumber() to get the serial
number of the device.

http://home.intermec.com/eprise/main/Intermec/Content/Support/DevelopersSupport/IDL_Support

Hope this helps,
Cheers,
Arun.
www.innasite.com



[quoted text, click to view]
Re: Eletronic Serial Number Darren Beckley
1/12/2007 6:49:23 PM
You can use ITCGetSerialNumber() from the Intermec Device Resource Kit to do
this. It's a native function, but is easy to P/Invoke e.g.

using System.Text;
using System.Runtime.InteropServices;

[DllImport("itc50.dll")]
private static extern int ITCGetSerialNumber(StringBuilder buffer,
int bufferSize);

public string GetSerialNumber()
{
// Serial number is 11 digits
StringBuilder buffer = new StringBuilder(12);

// Returns HRESULT so non-negative result means success
if (ITCGetSerialNumber(buffer, buffer.Capacity) >= 0)
{
return buffer.ToString();
}
else
{
return "00000000000";
}
}

Note that itc50.dll should already be installed by default on your CN3.

You can download Resource Kits for accessing other Intermec-specific
functionality from the Intermec Developers Library at
http://www.intermec.com/idl

Hope that helps,
Darren

[quoted text, click to view]

AddThis Social Bookmark Button