91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 1.02MB
    文件類型: .zip
    金幣: 2
    下載: 0 次
    發(fā)布日期: 2023-08-14
  • 語言: C#
  • 標簽: 打包程序??C#安裝包??

資源簡介

http://download.csdn.net/detail/shaohuatsou/5033123 是為該資源上傳的源代碼 之前用的打包程序都是VS自帶的或者是第三方的打包程序,雖然提供了很多自定義的操作和界面,但始終想自己研究下原理,然后自己就用C#寫了一個安裝包。 該安裝包安裝之后會在開始菜單和桌面創(chuàng)建快捷方式,系統(tǒng)的添加刪除程序項,系統(tǒng)服務項,并釋放幾個測試程序。 卸載的時候會一并清理干凈,不會留下任何殘留項。

資源截圖

代碼片段和文件信息

using?System;
using?System.Collections.Generic;
using?System.ComponentModel;
using?System.Data;
using?System.Drawing;
using?System.Linq;
using?System.Text;
using?System.Windows.Forms;
using?System.Runtime.InteropServices;
using?System.IO;
using?System.Threading;
using?Microsoft.Win32;
using?System.ServiceProcess;
using?System.Diagnostics;

namespace?Installation
{
????public?partial?class?FrmInstallation?:?Form
????{
????????///?
????????///?可填充區(qū)域,用戶可根據(jù)實際安裝需求更改此項
????????///?

????????public?string?strCompanyNameEnglish?=?“XYBarcode“;
????????public?string?strProductNameEnglish?=?“MESBarcodeServer“;
????????public?string?strServiceNameEnglish?=?“MES?Barcode?Server“;
????????public?string?strCompanyURL?=?“http://www.xybarcode.com“;

????????///?
????????///?程序變量,請勿更改
????????///?

????????private?string?strInstallationPath?=?““;
????????private?bool?bExpansion?=?false?bDesktoplink?=?true?bStartMenulink?=?true?bStartBarlink?=?true?bUserExperience?=?true;
????????private?int?iFormSizeHeightNor?=?360?iFormSizeHeightExp?=?470;
????????private?string?strResult?=?““;
????????private?FolderBrowserDialog?fbd?=?new?FolderBrowserDialog();

????????#region?拖動無邊框窗體
????????[DllImport(“user32.dll“)]
????????public?static?extern?bool?ReleaseCapture();//改變窗體大小
????????[DllImport(“user32.dll“)]
????????public?static?extern?bool?SendMessage(IntPtr?hwnd?int?wMsg?int?wParam?int?lParam);//發(fā)送windows消息
????????#endregion

????????#region?窗體邊框陰影效果變量申明
????????const?int?CS_DropSHADOW?=?0x20000;
????????const?int?GCL_style?=?(-26);
????????//聲明Win32?API
????????[DllImport(“user32.dll“?CharSet?=?CharSet.Auto)]
????????public?static?extern?int?SetClassLong(IntPtr?hwnd?int?nIndex?int?dwNewLong);
????????[DllImport(“user32.dll“?CharSet?=?CharSet.Auto)]
????????public?static?extern?int?GetClassLong(IntPtr?hwnd?int?nIndex);
????????#endregion

????????public?FrmInstallation()
????????{
????????????InitializeComponent();
????????????fbd.RootFolder?=?System.Environment.SpecialFolder.Desktop;
????????????fbd.SelectedPath?=?Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles);
????????????fbd.ShowNewFolderButton?=?true;
????????????txtPath.Text?=?fbd.SelectedPath?+?“\\“?+?strCompanyNameEnglish?+?“\\“?+?strProductNameEnglish;

????????????SetClassLong(this.Handle?GCL_style?GetClassLong(this.Handle?GCL_style)?|?CS_DropSHADOW);?//API函數(shù)加載,實現(xiàn)窗體邊框陰影效果
????????????lblMaintitle.Text?=?Application.ProductName;
????????????this.Text?=?Application.ProductName?+?“安裝程序“;
????????????this.Icon?=?Installation.Properties.Resources.Installation;
????????????lblCompanyName.Text?=?Application.CompanyName;
????????}

????????private?void?FrmMain_Load(object?sender?EventArgs?e)
????????{
????????????ThreadPool.QueueUserWorkItem(new?WaitCallback(ShowMain)?null);
????????}

????????private?void?ShowMain(object?obj)
????????{
????????????while?(this.Opacity!=1)
???

?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2013-06-27?11:46??Installation\
?????目錄???????????0??2013-05-06?10:29??Installation\bin\
?????目錄???????????0??2013-07-09?21:47??Installation\bin\Debug\
?????文件?????1643008??2013-07-09?21:47??Installation\bin\Debug\Installation.exe
?????文件???????79360??2013-07-09?21:47??Installation\bin\Debug\Installation.pdb
?????目錄???????????0??2013-05-06?10:29??Installation\Common\
?????文件????????9876??2013-05-06?10:29??Installation\Common\Shortcut.cs
?????文件???????26524??2013-05-06?10:36??Installation\FrmInstallation.cs
?????文件???????29151??2013-05-06?10:29??Installation\FrmInstallation.Designer.cs
?????文件????????5814??2013-01-27?11:17??Installation\FrmInstallation.resx
?????文件????????5344??2013-05-06?10:29??Installation\FrmMsg.cs
?????文件????????8510??2013-05-06?10:29??Installation\FrmMsg.Designer.cs
?????文件????????5814??2013-01-26?14:00??Installation\FrmMsg.resx
?????文件????????8366??2013-05-06?10:29??Installation\Installation.csproj
?????文件?????????488??2013-01-27?14:04??Installation\Installation.csproj.user
?????文件??????309830??2013-01-25?11:13??Installation\Installation.ico
?????目錄???????????0??2013-06-27?11:46??Installation\obj\
?????目錄???????????0??2013-08-03?09:52??Installation\obj\Debug\
?????文件?????????962??2013-07-09?21:47??Installation\obj\Debug\Installation.csproj.FileListAbsolute.txt
?????文件????????1187??2013-07-09?21:47??Installation\obj\Debug\Installation.csproj.GenerateResource.Cache
?????文件?????1643008??2013-07-09?21:47??Installation\obj\Debug\Installation.exe
?????文件?????????180??2013-07-09?21:47??Installation\obj\Debug\Installation.FrmInstallation.resources
?????文件?????????180??2013-07-09?21:47??Installation\obj\Debug\Installation.FrmMsg.resources
?????文件???????79360??2013-07-09?21:47??Installation\obj\Debug\Installation.pdb
?????文件??????865650??2013-07-09?21:47??Installation\obj\Debug\Installation.Properties.InstallFiles.resources
?????文件??????424057??2013-07-09?21:47??Installation\obj\Debug\Installation.Properties.Resources.resources
?????目錄???????????0??2013-08-03?09:52??Installation\obj\Debug\Refactor\
?????目錄???????????0??2013-06-27?11:46??Installation\obj\Debug\TempPE\
?????文件????????2137??2013-05-06?10:29??Installation\Program.cs
?????目錄???????????0??2013-07-09?21:47??Installation\Properties\
?????文件????????1444??2013-07-09?21:47??Installation\Properties\AssemblyInfo.cs
............此處省略102個文件信息

評論

共有 條評論