In winforms I already have a launcher(Launcher.exe) that just launches my main Program.exe with something like this:
Process proc = new Process ();
proc.StartInfo.FileName = kernelFile;
proc.StartInfo.WorkingDirectory = kernelPath;
proc.StartInfo.Arguments = arguments;
proc.Start ();
But it is also launchable by just clicking the main Program.exe. So my boss decided I should make my Program.exe into something that is not .exe so I could not launch it directly.
So my ways of approaching this would be:
- Make that executable into class library and somehow launch the .dll as a .exe.
- Add some kind of an argument when launching the process from launcher so the main program wouldn't start without that argument.
Any other ideas? which one should I stick with?