將來會用到

如何對 [Windows 服務] 與 [安裝專案的自訂動作] 進行除錯

 

文章標籤

Robert 發表在 痞客邦 留言(0) 人氣()

VSTO – How to build a setup project which targets x64 bit OS, and add custom Registry Launch Condition that checks if a key is found in the native 64bit registry hive.

還沒用到,先記錄起來...

 

文章標籤

Robert 發表在 痞客邦 留言(0) 人氣()

更新:
真正要找的資料找到了!
Microsoft Locale ID Values

文章標籤

Robert 發表在 痞客邦 留言(0) 人氣()

參考:
How to use the Orca database editor to edit Windows Installer files
How to change the file permissions in Windows Installer file

文章標籤

Robert 發表在 痞客邦 留言(0) 人氣()

這裡有些參考資料:
Create custom dialogs for an Setup project in Visual Studio 2015

使用 Orca 會用到的參考資料:

文章標籤

Robert 發表在 痞客邦 留言(0) 人氣()

好文暫存:C#綜合揭祕—通過修改登錄檔建立Windows自定義協議

原文(簡體):C#综合揭秘——通过修改注册表建立Windows自定义协议

 

文章標籤

Robert 發表在 痞客邦 留言(0) 人氣()

#文章保存
從:Wayback Machine
撈回來

文章標籤

Robert 發表在 痞客邦 留言(0) 人氣()

在安裝程式中,有時會遇到它的設計是:
移除的檔案 若所在的資料夾 有其他檔案或資料夾,就只把安裝的檔案刪除,仍留下其他(可能是使用者自己放進去)的檔案/資料夾。
以下是用程式實作的範例:

文章標籤

Robert 發表在 痞客邦 留言(0) 人氣()

System.Configuration.Install.Installer

  1. 有 "base.OnAfterInstall( savedState );"  才會觸發"AfterInstall"事件.
    1. "OnAfterInstall_base"
    2. "AfterInstall"
    3. "OnAfterInstall"
  2. 沒有 "base.OnAfterInstall( savedState );"  "OnAfterInstall"一律優先執行.
    1. "OnAfterInstall_base"
    2. "OnAfterInstall"

程式碼:

public InstallerHelp() : base()
{
    // 綁定完成安裝事件的處理方法.
    this.AfterInstall += new InstallEventHandler( CustomAfterInstall );
}
private void CustomAfterInstall( object sender, InstallEventArgs e )
{
    MessageBox.Show( "AfterInstall" );
}
protected override void OnAfterInstall( IDictionary savedState )
{
    MessageBox.Show( "OnAfterInstall_base" );
    base.OnAfterInstall( savedState );  // 觸發"AfterInstall"事件.
    MessageBox.Show( "OnAfterInstall" );
}

 

文章標籤

Robert 發表在 痞客邦 留言(0) 人氣()

  1. 在你的專案底下,建立一個 class ,繼承 System.Configuration.Install.Installer
        範例:
    [RunInstaller(true)]
    public partial class InstallerHelp : Installer
    {
        public override void Install(IDictionary stateSaver)
        {
            base.Install(stateSaver);
    
            string strKey = Context.Parameters[“KeyValue”];
            string sPath = @”c:\Test.txt”;
    
            if (File.Exists(sPath))
                File.Delete(sPath);
            File.WriteAllText(sPath, strKey);
        }
    }
  2. 在你的 Installer Porject 右鍵 ->「View」->「檔案系統」;
        「Application Folder」-> 右鍵 ->「Add」->「專案輸出」;
文章標籤

Robert 發表在 痞客邦 留言(1) 人氣()