Click here to Skip to main content
15,907,396 members
Home / Discussions / C#
   

C#

 
GeneralRe: question Pin
CPallini14-Jan-09 9:12
mveCPallini14-Jan-09 9:12 
AnswerRe: question Pin
Mohammad Dayyan14-Jan-09 8:17
Mohammad Dayyan14-Jan-09 8:17 
GeneralNavigate Code Like Web Browser... Pin
code-frog14-Jan-09 2:57
professionalcode-frog14-Jan-09 2:57 
GeneralRe: Navigate Code Like Web Browser... Pin
Christian Graus14-Jan-09 3:04
protectorChristian Graus14-Jan-09 3:04 
GeneralRe: Navigate Code Like Web Browser... Pin
User 665814-Jan-09 3:27
User 665814-Jan-09 3:27 
GeneralRe: Navigate Code Like Web Browser... [modified] Pin
vaghelabhavesh14-Jan-09 7:11
vaghelabhavesh14-Jan-09 7:11 
QuestionWindows Services Related Pin
CH SRINIW8Z14-Jan-09 2:54
CH SRINIW8Z14-Jan-09 2:54 
AnswerRe: Windows Services Related Pin
musefan14-Jan-09 2:57
musefan14-Jan-09 2:57 
AnswerRe: Windows Services Related Pin
PIEBALDconsult14-Jan-09 4:52
mvePIEBALDconsult14-Jan-09 4:52 
QuestionDisplaying Image and text together in a single cell of datagridview Pin
Lijo Rajan14-Jan-09 2:08
Lijo Rajan14-Jan-09 2:08 
AnswerRe: Displaying Image and text together in a single cell of datagridview Pin
Dave Kreskowiak14-Jan-09 3:46
mveDave Kreskowiak14-Jan-09 3:46 
GeneralRe: Displaying Image and text together in a single cell of datagridview Pin
nelsonpaixao15-Jan-09 6:39
nelsonpaixao15-Jan-09 6:39 
GeneralRe: Displaying Image and text together in a single cell of datagridview Pin
Lijo Rajan16-Jan-09 18:02
Lijo Rajan16-Jan-09 18:02 
GeneralRe: Displaying Image and text together in a single cell of datagridview Pin
nelsonpaixao17-Jan-09 3:26
nelsonpaixao17-Jan-09 3:26 
QuestionNo GUI when I create process on remote PC Pin
Programm3r14-Jan-09 1:56
Programm3r14-Jan-09 1:56 
Hi all,

Currently I'm creating a process on a remote PC, the problem is that there is no UI that appears when the process starts. When I navigate to the task manager I can see the process in the process list, but nothing with regards to the UI.

I am make use of the following code:
ConnectionOptions options = new ConnectionOptions();
options.EnablePrivileges = true;
options.Authentication = AuthenticationLevel.Connect;
options.Impersonation = ImpersonationLevel.Impersonate;
//options.Password = "password";
//options.Username = @"user";

string SystemName = "PC_NAME";
string Path = string.Format(@"\\{0}\root\cimv2", SystemName);

ManagementScope ms = new ManagementScope(Path);
ms.Connect();

ManagementPath processMgmtpath = new ManagementPath("Win32_Process");
ManagementClass processClass = new ManagementClass(ms, processMgmtpath, null);
ManagementPath processStartupMgmtpath = new ManagementPath("Win32_ProcessStartup");
ManagementClass processStartup = new ManagementClass(ms, processStartupMgmtpath, null);

ManagementBaseObject inParams = processClass.GetMethodParameters("Create");
inParams["CommandLine"] = @"c:\Application.exe";
inParams["CurrentDirectory"] = @"c:\";
inParams["ProcessStartupInformation"] = null;
ManagementBaseObject ReturnObj = processClass.InvokeMethod("Create", inParams, null);
Console.WriteLine("RC={0}", ReturnObj["returnValue"].ToString());


Many thanks in advance
Kind regards,


The only programmers that are better those C# programmers are those who code in 1's and 0's Green Alien | [Alien]



Smile | :) Programm3r

My Blog: ^_^

AnswerRe: No GUI when I create process on remote PC Pin
Christian Graus14-Jan-09 2:26
protectorChristian Graus14-Jan-09 2:26 
GeneralRe: No GUI when I create process on remote PC Pin
Programm3r14-Jan-09 2:40
Programm3r14-Jan-09 2:40 
GeneralRe: No GUI when I create process on remote PC Pin
Christian Graus14-Jan-09 3:05
protectorChristian Graus14-Jan-09 3:05 
GeneralRe: No GUI when I create process on remote PC Pin
Programm3r14-Jan-09 3:14
Programm3r14-Jan-09 3:14 
GeneralRe: No GUI when I create process on remote PC Pin
Programm3r14-Jan-09 2:54
Programm3r14-Jan-09 2:54 
GeneralRe: No GUI when I create process on remote PC Pin
Programm3r14-Jan-09 3:17
Programm3r14-Jan-09 3:17 
AnswerRe: No GUI when I create process on remote PC Pin
Dave Kreskowiak14-Jan-09 3:44
mveDave Kreskowiak14-Jan-09 3:44 
Questionadapter.fill method Catch and Finally block do not execute Pin
mpavas14-Jan-09 1:56
mpavas14-Jan-09 1:56 
AnswerRe: adapter.fill method Catch and Finally block do not execute Pin
Colin Angus Mackay14-Jan-09 2:04
Colin Angus Mackay14-Jan-09 2:04 
AnswerRe: adapter.fill method Catch and Finally block do not execute Pin
Christian Graus14-Jan-09 2:27
protectorChristian Graus14-Jan-09 2:27 

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.