.NET (C# ) Install Project. Including other packages problem

只愿长相守 提交于 2019-12-24 00:53:13

问题


folks. I've created a setup project in VS2008 which installs fine by itself. However projects being installed by this installer depend on components (mainly speaking ESRI) which must also be installed on target machines. There is a separate installer for ESRI that we have and it consists of msi srcipt as well as 6 folders with subfolders in those which are user by this msi. I can't seem to figure out how to include that into my setup project, so that target users just run one full package. I tried the following which almost works: 1.Created one more class library project in the solution 2.Added installer class to it 3.Overrode Install method and wrote

string path=Assembly.GetExecutingAssembly().Location;
Process.Start(Path.Combine(path, "esriinstaller.msi"));

4.Added msi file to output folder's pane in installer project This does not quite work b/c: a)path doesn't point to directory where the installer was launched (in fact I tried various combinations of Assembly.Get...().BasePath methods - these yield either Windows\System32 or target folder) b)I also have to manually copy all ESRI folders into installer's package dir (...bin\Release)

So, is there a literate way to add that package to my installer? (I configured .NET dependencies in Detected Dependencies properties dialog box to install those from full dotnetfix included in the package and it worked fine, and I thought may be I could somehow force installer to "think" that ESRI is also dependendent on project, but with no results yet). Any suggestions?

Now, we also need to automate some installer packages (like SqlServer2008) to minimize user interraction. In fact, we would like to supress some dialogs from installer (do not offer to use SoftIce - we are not hackers, unfortunetly). A friend of mine has pointed to some AutoIt project. Is that it?


回答1:


You can add custom prerequisites to bootstrap any redistributable package. Please check the following links.

Adding Custom Prerequisites: http://msdn.microsoft.com/en-us/library/ms165429(VS.80).aspx

Creating Custom Packages: http://msdn.microsoft.com/en-us/library/ms165429.aspx



来源:https://stackoverflow.com/questions/3785916/net-c-install-project-including-other-packages-problem

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!