Show form in Custom Installer in C#.Net
[RunInstaller(true)]
public partial class Installer1 : Installer
{
public Installer1()
{
InitializeComponent();
}
public override void Install(System.Collections.IDictionary stateSaver)
{
base.Install(stateSaver);
}
private void In开发者_运维百科staller1_AfterInstall(object sender, InstallEventArgs e)
{
Form1 topmostForm = new Form1();
topmostForm.BringToFront();
topmostForm.TopMost = true;
topmostForm.ShowDialog();
}
}
When i Call topmostForm.ShowDialog() that time form is shown in back side of default installer screen. I want to it front side. I think you got my idea.... Please help me....
What worked for me was to call Activate
from the Form.Load
event.
private void Form1_Load(object sender, EventArgs e)
{
Active();
}
精彩评论