2011-06-03 51 views
1
[RunInstaller(true)] 
public partial class Installer1 : Installer 
{ 
    public Installer1() 
    { 
     InitializeComponent(); 
    } 

    public override void Install(System.Collections.IDictionary stateSaver) 
    { 
     base.Install(stateSaver); 
    } 
    private void Installer1_AfterInstall(object sender, InstallEventArgs e) 
    { 
     Form1 topmostForm = new Form1(); 
     topmostForm.BringToFront(); 
     topmostForm.TopMost = true;    
     topmostForm.ShowDialog(); 
    } 
} 

當我調用topmostForm.ShowDialog()時,窗體顯示在默認安裝程序屏幕的背面。 我想要正面。 我認爲你有我的主意...... 請幫我....在C#.Net中的自定義安裝程序中顯示窗體

回答

1

對我來說有效的是從Form.Load事件中撥打Activate

private void Form1_Load(object sender, EventArgs e) 
{ 
    Active(); 
} 
相關問題