Make your own setup
In vs.net, we can build "setup and deployment projects" project, very flexible and convenient to own. Net programs produced for the windows installer file. For example, we can easily customize the following options:
1. Whether to place a shortcut on the desktop.
2. Register your own file types, you can double click the file to use his program to open.
3. Registry of Treatment
In the following msdn site, we can get through in vs.net setup and deployment projects to make your own setup example: http://msdn.microsoft.com/library/en-us/vsinspano7/html/vbcondeploymentscenarios. asp
Release. Net framework
. Net framework 1.0 is used to provide a redeployment. Net the exe file: dotnetfx.exe. It contains the common language runtime and the other. Net program runs essential element.
We can see from the following site to download the exe file: http://msdn.microsoft.com/downloads/sample.asp?url=/msdn-files/027/001/829/msdncompositedoc.xml
At the same time, we can also install cd or dvd in vs.net found in the file.
We can run the dotnetfx.exe by a variety of ways to. Net framework deployment to the target machine:
1. Through the microsoft systems management server deployment.
2. Through the active directory deployment.
3. To use third-party tools.
Specific information, we can see the following article:
http://msdn.microsoft.com/library/en-us/dnnespanep/html/redisspaneploy.asp
Make your own native installer
If we want to own. Net program released to the target machine, and we are unsure whether the target machine has been installed. Net framework, then we need to design their own section of unmanaged code to determine whether the target machine is installed. Net framework If not, then run the dotnetfx.exe to install. net framework, and then use windows installer to install your own program.
In the following msdn page, we can get one using unmanaged c + + implementation of the installation program and its source code:
http://msdn.microsoft.com/downloads/default.asp?url=/code/sample.asp?url=/msdn-files/027/001/830/msdncompositedoc.xml
1. Csettings class, by reading "settings.ini", get your own msi installation files and the way dotnetfx.exe
Diameter, and other settings of your own. (Such as. Net framework language version)
getcaptiontext (void)
getdialogtext (void)
geterrorcaptiontext (void)
getininame (void)
getproductname (void)
parse () function is used to resolve settings.ini file.
2. Main.cpp file, global function fxinstallrequired () to determine whether the target machine to install. Net framework. Fxinstallrequired () will check the following registry key and dotnetfx.exe version and language settings.
hklmsoftwaremicrosoft.netframeworkpolicyv1.0
3. If you need to install. Net framework, the global function execcmd () call the following command silent install dotnetfx.exe: dotnetfx.exe / q: a / c: "install / l / q"
4. Execcmd () global function to call the following command to install your own msi file: msiexec / i reboot = reallysuppress
Use
If we use the above native code as their own installation program, then we can through the following steps to their own. Net program and its combination of:
1. To your own. Net program make a windows installer (. Msi) file.
銆??2.鎵撳紑"settings.ini"鏂囦欢锛屽湪"msi" key涓缃偍鑷繁鐨?net绋嬪簭鐨刴si鏂囦欢璺緞鍜屾枃浠跺悕;鍦?amp;quot;fxinstallerpath" key涓紝璁剧疆dotnetfx.exe鐨勮矾寰勩?鍏蜂綋鐨勫弬鏁颁俊鎭紝鎮ㄥ彲浠ヤ粠涓嬮潰鏂囩珷涓緱鍒帮細
銆??http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnespanep/html/redisspaneploy.asp
銆??3. 鎶?amp;quot;setup.exe", "settings.ini", "dotnetfx.exe"鍜屾偍鑷繁鐨刴si瀹夎鏂囦欢锛屽彂閫佸埌鐩爣鏈哄櫒涓婏紝鐒跺悗杩愯"setup.exe", 瀹夎绋嬪簭浼氳嚜鍔ㄦ娴嬫槸鍚︽湁.net framwork, 濡傛灉娌℃湁锛屽皢棣栧厛杩愯dotnetfx.exe銆?br />
Summary
銆??閫氳繃涓婅堪姝ラ锛屾偍鍙互灏嗚嚜宸辩殑.net绋嬪簭鎴愬姛鐨勯儴缃插埌娌℃湁瀹夎.net framwork鐜鐨勬満鍣ㄤ笂銆?br />
相关链接:
New Graphic CAD
Svchost.exe application error how to repair
CREDENTIAL is actually very simple
VBScript MONTH function
20 cases of ASP programming utility
MSN users frequently worry about Strangers raid computer data leakage
DV To AVI
"Chino Conflict" Comment
Catalogs Basic Or VB Or VB DotNet
Log Analysers Specialist
Railway
Asp.Net based learning instance: graphic output
FLV to VOB
UC: A Master Of A MS
British grams, Novel Medicine 1000 Chain layout help
MPG TO AVI
No comments:
Post a Comment