I have done that... I have found this ProccessPrileges and it looks like it has fixed my issues
MeekLogic
Posts
-
System.Diagnostics.Process Help -
System.Diagnostics.Process Help.Net 3.5 and yes on Vista
-
System.Diagnostics.Process HelpDeclaring
AobotProc = new Process(); AobotProc.StartInfo.FileName = AOPath + "//" + AOExe; AobotProc.StartInfo.Arguments = "-run -hide"; AobotProc.StartInfo.WorkingDirectory = AOPath; AobotProc.EnableRaisingEvents = true; AobotProc.Start(); AobotProc.Exited += new EventHandler(aobot\_proc\_Exited);
and errors wen
if (AobotProc != null && !AobotProc.HasExited) { if (!AobotProc.CloseMainWindow()) AobotProc.Kill(); }
errors at AobotProc.HasExited saying Access Is Denied
-
degree of multithreading(analyze)LOL threads come and go in programs, and it will change depending on what your doing in the app and perfect timing. And seriously what is "degree of multi threading"?
-
Dragging the form.... please help!No problem man I was really pissed when I first realized that also and found that code somewhere Google searching :)
-
Dragging the form.... please help!Just add this code to your form :)
protected override void WndProc(ref Message m) { if (m.Msg == 0x0084 /\*WM\_NCHITTEST\*/) { m.Result = (IntPtr)2; // HTCLIENT return; } base.WndProc(ref m); }
-
System.Diagnostics.Process HelpOk I have been having the most trouble with the Process class. It keeps throw Access Is Denied for everything. I stumbled across this.
[HostProtectionAttribute(SecurityAction.LinkDemand, SharedState = true, Synchronization = true,
ExternalProcessMgmt = true, SelfAffectingProcessMgmt = true)]
[PermissionSetAttribute(SecurityAction.LinkDemand, Name="FullTrust")]
[PermissionSetAttribute(SecurityAction.InheritanceDemand, Name = "FullTrust")]Now I have no clue about this but I know your supposed to put above a func, constructor and all that. How can I just give my app all these permissions. Or better yet is there a better way to stop these rediculous exceptions. It happens on HasExited, Kill, Close, etc.
modified on Monday, May 4, 2009 2:03 AM
-
RegisterHotKey helpI want to modify this RegisterHotKey func to allow me to set it using HashKey instead of a shortcut key but I'm not exactly sure how to do this. this is the code for registering the hotkey in the object
protected bool RegisterHotkey(Shortcut key) { //register hotkey int mod=0; Keys k2=Keys.None; if (((int)key & (int)Keys.Alt)==(int)Keys.Alt) {mod+=(int)Win32.Modifiers.MOD\_ALT;k2=Keys.Alt;} if (((int)key & (int)Keys.Shift)==(int)Keys.Shift) {mod+=(int)Win32.Modifiers.MOD\_SHIFT;k2=Keys.Shift;} if (((int)key & (int)Keys.Control)==(int)Keys.Control) {mod+=(int)Win32.Modifiers.MOD\_CONTROL;k2=Keys.Control;} System.Diagnostics.Debug.Write(mod.ToString()+" "); System.Diagnostics.Debug.WriteLine((((int)key)-((int)k2)).ToString()); return Win32.User32.RegisterHotKey(m\_Window.Handle, this.GetType().GetHashCode(), (int)mod, ((int)key) - ((int)k2)); }