Click here to Skip to main content
15,898,374 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
QuestionGet a Month collection class Pin
Vipul Mehta13-Oct-06 2:18
Vipul Mehta13-Oct-06 2:18 
AnswerRe: Get a Month collection class Pin
Dave Kreskowiak13-Oct-06 5:41
mveDave Kreskowiak13-Oct-06 5:41 
AnswerRe: Get a Month collection class Pin
Bob X15-Oct-06 14:35
Bob X15-Oct-06 14:35 
AnswerRe: Get a Month collection class Pin
MGoettmann19-Oct-06 23:20
MGoettmann19-Oct-06 23:20 
QuestionHex/decimal/binary textbox. How? Pin
lclarsen13-Oct-06 1:54
lclarsen13-Oct-06 1:54 
AnswerRe: Hex/decimal/binary textbox. How? Pin
Bob X15-Oct-06 15:15
Bob X15-Oct-06 15:15 
QuestionHow to get process's user and domain without WMI Pin
Dave Midgley13-Oct-06 1:17
Dave Midgley13-Oct-06 1:17 
AnswerRe: How to get process's user and domain without WMI Pin
Mike Dimmick13-Oct-06 5:02
Mike Dimmick13-Oct-06 5:02 
The Windows API calls you will need are: OpenProcess to get a handle to the process (ask for PROCESS_QUERY_INFORMATION rights), OpenProcessToken to get a handle to the process's token (ask for TOKEN_QUERY rights), and GetTokenInformation to get the user account associated with the token (pass TokenUser as the second parameter).

That will get you the user's security identifier (SID). You then need to use the LookupAccountSid API to turn that back into a username and domain.

You can find sample P/Invoke declarations at www.pinvoke.net[^].

Stability. What an interesting concept. -- Chris Maunder

GeneralRe: How to get process's user and domain without WMI Pin
Dave Midgley20-Oct-06 0:14
Dave Midgley20-Oct-06 0:14 
QuestionBackground process to automatically deliver mails for certain conditions Pin
Renukapadhamanaban12-Oct-06 16:25
Renukapadhamanaban12-Oct-06 16:25 
QuestionHow can i creat subcategory in the property definition Pin
Lior S12-Oct-06 7:08
Lior S12-Oct-06 7:08 
QuestionProblem in Interop Pin
He is Cool12-Oct-06 5:31
He is Cool12-Oct-06 5:31 
Questionenabling disabling LAN card in shell Pin
Tauseef A12-Oct-06 0:13
Tauseef A12-Oct-06 0:13 
AnswerRe: enabling disabling LAN card in shell Pin
Dave Kreskowiak12-Oct-06 6:34
mveDave Kreskowiak12-Oct-06 6:34 
GeneralRe: enabling disabling LAN card in shell Pin
Tauseef A12-Oct-06 21:53
Tauseef A12-Oct-06 21:53 
QuestionRe: enabling disabling LAN card in shell Pin
Tauseef A15-Oct-06 4:39
Tauseef A15-Oct-06 4:39 
Question.NET Wizard problem. Pin
He is Cool11-Oct-06 22:52
He is Cool11-Oct-06 22:52 
QuestionWMI and c#.net Pin
Tauseef A11-Oct-06 22:28
Tauseef A11-Oct-06 22:28 
AnswerRe: WMI and c#.net Pin
Dave Kreskowiak12-Oct-06 6:23
mveDave Kreskowiak12-Oct-06 6:23 
QuestionRe: WMI and c#.net [modified] Pin
Tauseef A12-Oct-06 22:09
Tauseef A12-Oct-06 22:09 
AnswerRe: WMI and c#.net Pin
Dave Kreskowiak13-Oct-06 1:44
mveDave Kreskowiak13-Oct-06 1:44 
QuestionRe: WMI and c#.net Pin
Tauseef A13-Oct-06 4:40
Tauseef A13-Oct-06 4:40 
AnswerRe: WMI and c#.net Pin
Dave Kreskowiak13-Oct-06 4:46
mveDave Kreskowiak13-Oct-06 4:46 
QuestionHow come fewer files? Pin
mysorian11-Oct-06 12:33
professionalmysorian11-Oct-06 12:33 
AnswerRe: How come fewer files? Pin
WillemM15-Oct-06 0:42
WillemM15-Oct-06 0:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.