Solved

Getting System Name or Device Name for Pocket PC 2002 using .NET Compact Framework

Posted on 2003-11-18
5
896 Views
Last Modified: 2013-12-27
I am programming in .Net compact framework and using vb.net at the moment. I am porting over a desktop program to pocket pc having to recode most of the things, if not all. My question is: I used to use Environ("ComputerName") in vb 6 to get the computer name in order to identify this client that is going to connect to my remote database server running on SQL Server 2000. Now, I need to do the same on a pocket PC and i found out there's System name property under asset viewer>my pocket pc>Identity>System name which is equilvalent to About>Device ID tab > Device name, which i believe could be an equilvalent for a computername under windows Environment.

Can someone enlighten me on how to get this done in VB.net or even c#.net under .net compact framework?
0
Comment
Question by:imchris
5 Comments
 
LVL 48

Accepted Solution

by:
Mikal613 earned 125 total points
ID: 9779704
0
 

Expert Comment

by:papte
ID: 10135483
Hi,

The Device name is there in the registry at[HKEY_LOCAL_MACHINE\Ident] .
I did registry editing in VC6 using RegQueryValueEx() & RegOpenKeyEx().

0
 
LVL 7

Expert Comment

by:CJCraft
ID: 10303931
You can get the Device ID using the following:
http://samples.gotdotnet.com/quickstart/CompactFramework/doc/deviceid.aspx

It is the serial number for the device.

You should be able to get the device name using the following:
System.Net.Dns.GetHostName();
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Exchange ActiveSync Connection error 4 75
Backup contact in Nokia Lumia 525 4 489
determining network device capabilities 2 102
Practical VPN Setup 9 70
This article shows how to setup the internet connectivity on Windows Mobile Emulator.   I assume that you already have Microsoft Visual Studio, Microsoft Windows Mobile SDK's and the emulator installed. The emulator is available with Visual Studi…
Preface: This article is part of a series focused on cross platform mobile app development (specifically Android and iOS) using the Alloy framework and Titanium Studio made by Appcelerator (https://www.appcelerator.com/). This article presumes a wor…
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, just open a new email message. In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now