i'm trying to develop an c# app integrated with the windows shell, because of this i'm using the sharpshell library. i'm using the sharpshell library directly in the same project, creating a dedicated class for handle the context menu. originally i linked to the click event on the context menu the following command:
System.Diagnostics.Process.Start(path, _command.ToString() + "|" + string.Join("|", SelectedItemPaths));
and the system was working. now i'm trying to start directly from the Click event a new istance of the Program.Main class with the following code:
DmsDrive.Program.Main(new string[] { _command.ToString() + "|" + string.Join("|", SelectedItemPaths) });
and the istance is working and starts properly. the problem is that starting the process using this method make the programm to look for app.config into the windows directory (the main currentdomain is the explorer.exe process). because of this the app.config isn't loaded and the contract to the wcf service don't works.
do you know how can i handle this? or is it better that i continue to use the Process.start method?
Regards.