I have an application which needs many prerequisites. For installing this application and install all prerequisites I have written another c# application (myAppInstaller.exe). This installer should do the complete installation (I don't want a separate installer like installshield...).
Now I would like to put the myAppInstaller.exe and all Tools, programs, Batches, Files etc. which are needed on a Network directory, so all users could click the myAppInstaller.exe on the Network path and the application will be installed on local pc. For example the user clicks N:\Software\MyApp\myAppInstaller.exe. This c# installer calls now a bat-file which calls for example "dism /online /enable-feature:IIS-WebServerRole".
Now the Problem: If the user executes the exe normally with doubleclick, the dism-call gives an error like "Admin rights needed". If the user executes the exe "run as Administrator", now the bat-file could not be found anymore. If I have all of the files on local Client, everything works with running as Administrator. Why is this not working when I call the exe on the networkpath?
Thank you very much for your help.