How can i get system or user information with cf?

  • Thread starter Thread starter Hans Hahn
  • Start date Start date
H

Hans Hahn

Hi,

In standard .net there is the environment class designed to get user name,
machine name, ... and many other infos like this. in the cf.net the
retrieved info is very limited.
how can i get the user name and the machine name with the cf.net.

thx Hans
 
Generally, if you can't find the information that you want in .NET CF
directly, look at the C SDK for the device and see what you can find there.
In this case, GetUserNameEx() might work for you, although you haven't told
us *anything* about your target device. The 'machine name' might be best
found via DNS.GetHostName().

Paul T.
 
Some of these settings are wrapped in the EnvironmentEx class in the SDF
(www.opennetcf.org/sdf/) which gets the data from the registry. The
MachineName implementation should work on any Windows CE flavour. The
Username property is a bit less universal, our class reads the owner info
from a Pocket PC/Smartphone.

Peter
 
Back
Top