I'm registering a dll at startup of my application by this command:
System.Diagnostics.Process.Start("regsvr32",strPath);
and after running this line of code , a window appears that says DLL registration was successful or not .
My question is that how can I hide this window in my application?
Use /s – Silent; display no message boxes (added with Windows XP and Windows Vista)
/s – Silent; display no message boxes (added with Windows XP and Windows Vista)
option.
Source: What is the different between /n and /i parameters of RegSvr32.exe?
Process proc = new Process
{
StartInfo =
{
FileName = "regsvr32",
Arguments = "/s" + strPath,
RedirectStandardError = true,
UseShellExecute = false,
CreateNoWindow = true
}
};
proc.Start();
Also you can do this:
System.Diagnostics.Process.Start("regsvr32","/s" + strPath);
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.