This is the first time I am creating an installation. I need some help on this.
I use the Publish option when creating my setup. When I finish installing, the setup installation path contains all the .cs files as they are visible during development. This allows any person who has VS installed to edit my application.
As an alternative I tried using Advanced Installer, but the same thing happens there too. I would like to continue using Advanced Installer as I would like to use their themes and Trial and Registration Features.
I am currently using the Trial And Registration feature of Advanced Installer. This feature creates a DLL in the installation directory. How do I use a relative path to link to my DLL?
Environment.CurrentDirectory = Directory.GetCurrentDirectory();
string dllPath = Path.GetFullPath(@"..\..\Trial.dll");
The above code works fine during development. But when I install the EXE, it returns an error. According to me there is an error in the path.
While installing I use this path:
C:\Program Files\ManufacturerName\AppName\
When the installation completes, the folders look like this:
C:\Program Files\ManufacturerName\AppName\<My CS files are here, on a silver platter>
C:\Program Files\ManufacturerName\AppName\bin\release
C:\Program Files\ManufacturerName\AppName\bin\release\<app.exe here>
C:\Program Files\ManufacturerName\AppName\bin\debug
C:\Program Files\ManufacturerName\AppName\obj\x86
C:\Program Files\ManufacturerName\AppName\obj\x86\release
C:\Program Files\ManufacturerName\AppName\obj\x86\debug
C:\Program Files\ManufacturerName\AppName\Properties
C:\Program Files\ManufacturerName\AppName\Service References
There are files present in these folders. It's the same as my project path.
I am also open to using other installers that allow me to have something by which I can have a one time installation.