Lanem,
You can use WMI, however in my opinion is this snippet simpler for your
question using the Environment variable
\\\\needs 1 listbox on a form
Dim environmentVariables As IDictionary _
= Environment.GetEnvironmentVariables()
Dim de As DictionaryEntry
ListBox1.Items.Clear()
For Each de In environmentVariables
Me.ListBox1.Items.Add(de.Key.ToString & _
"=" & de.Value.ToString)
Next de
////
You see that a list from things in de.Key and de.Value. One of them is
username, however it is more interesting to look to all so I did not select
that.
Cor