Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

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

Posted on 2003-11-18
5
Medium Priority
?
1,006 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
3 Comments
 
LVL 48

Accepted Solution

by:
Mikal613 earned 500 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

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

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…
Once again I push the limits of my phone.  An introduction to the Android Google Now Launcher.
this video summaries big data hadoop online training demo (http://onlineitguru.com/big-data-hadoop-online-training-placement.html) , and covers basics in big data hadoop .
Screencast - Getting to Know the Pipeline
Suggested Courses

876 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