Archived

This topic is now archived and is closed to further replies.

Mr Cucumber

Creating an installer for a C# solution

Recommended Posts

I''m creating a C# .net program which contains one .exe file and one .dll file. I need to create an installer for this program to let the user install my program from for example a cd. What is it I should do? I really have no idea. I know there is an installer class i .net but the documentation is terrible about how one uses it. Could anyone point out what I need to do?

Share this post


Link to post
Share on other sites
Does your program use the registry at all? If not then I would suggest creating an autorun written in Win32 or something that will check to see if the .NET framework is installed and if it isn''t, run the install program(include it in the CD) and if it already is then run a simple install program you can create that just copies the files to a directory you specify and adds the program to the start menu. If you know the framework is going to be installed on it then you may be able to just make a simple installer and do it that way. BTW-I''m not sure how your supposed to check to see if the framework is installed

Share this post


Link to post
Share on other sites
I think you can check to see if the .NET framework is installed by checking for the existance of:

HKLM\SOFTWARE\Microsoft\.NETFramework in the registry. Also instead of doing a 2 part install like I suggested you could do the whole installer in C/C++

Share this post


Link to post
Share on other sites
Why would you write the installer in C/C++ for a .NET-based app when VS can help you make one, and NSIS exists?

Unless you find reasons why NSIS doesn''t work for you I hope people don''t sit down and write their own installers.

Share this post


Link to post
Share on other sites
Uhh... I haven''t really looked into any other installers. Especially a free one like NSIS. You could just use NSIS like you sugested. The reason for an unmanaged one would be in case they don''t have the framework installed to bootstrap it, plus he said it was only two files needing to be copied. NSIS could serve this purpose apparently. NSIS looks interesting, thanks for the URL. You would probably have to change some sort of script to get it to install the framework but I''m sure that could be done easily.

Share this post


Link to post
Share on other sites