Click here to Skip to main content
15,925,369 members
Home / Discussions / C#
   

C#

 
AnswerRe: How do I create a demo for my application using C# Pin
mav.northwind27-Jun-07 8:18
mav.northwind27-Jun-07 8:18 
AnswerRe: How do I create a demo for my application using C# Pin
Dan Neely27-Jun-07 9:11
Dan Neely27-Jun-07 9:11 
AnswerRe: How do I create a demo for my application using C# Pin
I.explore.code27-Jun-07 18:25
I.explore.code27-Jun-07 18:25 
GeneralRe: How do I create a demo for my application using C# Pin
mav.northwind28-Jun-07 9:32
mav.northwind28-Jun-07 9:32 
QuestionGetting a window's icon Pin
sharpiesharpie27-Jun-07 6:28
sharpiesharpie27-Jun-07 6:28 
AnswerRe: Getting a window's icon Pin
Giorgi Dalakishvili27-Jun-07 6:43
mentorGiorgi Dalakishvili27-Jun-07 6:43 
Questionhow can I get a process(Especific Owner) Pin
jeguzmanv27-Jun-07 6:25
jeguzmanv27-Jun-07 6:25 
AnswerRe: how can I get a process(Especific Owner) Pin
Tarakeshwar Reddy27-Jun-07 6:32
professionalTarakeshwar Reddy27-Jun-07 6:32 
You can P/Invoke OpenProcessToken[^]. Get the token information and check if the username and the process name are the one you want and do the operation you need to do

Or use WMI

System.Management.ManagementObjectSearcher moSearch;
string sQuery = "";

System.Diagnostics.Process[] processes = System.Diagnostics.Process.GetProcessesByName("msiexec");

foreach (System.Diagnostics.Process p in processes)
{
	sQuery = "Select * From Win32_Process Where ProcessID = " + p.Id;
	moSearch = new System.Management.ManagementObjectSearcher(sQuery);
	string[] args = new string[5];

	foreach (System.Management.ManagementObject mo in moSearch.Get())
	{
		mo.InvokeMethod("GetOwner", args);
		if (args[0] == strCurrentUser)
                {
                   //do what you want
		}
	}
}



Questionhow can raise an event in c# ? [modified] Pin
B.A27-Jun-07 5:41
B.A27-Jun-07 5:41 
AnswerRe: how can raise an event in c# ? Pin
Not Active27-Jun-07 5:48
mentorNot Active27-Jun-07 5:48 
QuestionException handling doubt... Pin
Software_Specialist27-Jun-07 5:17
Software_Specialist27-Jun-07 5:17 
AnswerRe: Exception handling doubt... Pin
Colin Angus Mackay27-Jun-07 5:23
Colin Angus Mackay27-Jun-07 5:23 
GeneralRe: Exception handling doubt... Pin
Software_Specialist27-Jun-07 5:29
Software_Specialist27-Jun-07 5:29 
GeneralRe: Exception handling doubt... Pin
Colin Angus Mackay27-Jun-07 5:38
Colin Angus Mackay27-Jun-07 5:38 
JokeRe: Exception handling doubt... Pin
Not Active27-Jun-07 5:54
mentorNot Active27-Jun-07 5:54 
JokeSure? Pin
CPallini27-Jun-07 6:00
mveCPallini27-Jun-07 6:00 
GeneralRe: Sure? Pin
Dave Kreskowiak27-Jun-07 6:57
mveDave Kreskowiak27-Jun-07 6:57 
GeneralRe: Sure? Pin
CPallini27-Jun-07 10:06
mveCPallini27-Jun-07 10:06 
GeneralRe: Sure? Pin
Dave Kreskowiak27-Jun-07 10:15
mveDave Kreskowiak27-Jun-07 10:15 
GeneralRe: Sure? Pin
Dave Kreskowiak27-Jun-07 10:16
mveDave Kreskowiak27-Jun-07 10:16 
GeneralRe: Sure? Pin
CPallini27-Jun-07 10:20
mveCPallini27-Jun-07 10:20 
GeneralRe: Sure? Pin
Luc Pattyn27-Jun-07 11:00
sitebuilderLuc Pattyn27-Jun-07 11:00 
GeneralRe: Sure? Pin
Dave Kreskowiak27-Jun-07 11:59
mveDave Kreskowiak27-Jun-07 11:59 
AnswerRe: Exception handling doubt... Pin
gumi_r@msn.com27-Jun-07 5:57
gumi_r@msn.com27-Jun-07 5:57 
AnswerRe: Exception handling doubt... Pin
Vikram A Punathambekar27-Jun-07 18:20
Vikram A Punathambekar27-Jun-07 18:20 

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.