How do I get the About box to appear in C#?

It sounds to me like a borked designer surface... have you hit save and rebuilt it? Perhaps close the IDE, reopen it, and check that your carefully designed form is still pretty?

BTW, when using ShowDialog you should also use using (since it doesn't Dispose() itself when shown with ShowDialog):

using(AboutBox1 box = new AboutBox1()) {
    box.ShowDialog(this);
}

Got it.

The about box is driven off of assembly properties for your project.

Go to Project -> 'ProjectName' Properties -> Assembly Information.

You set all of the information there.

If you try to set the information in the Property Explorer it will simply be over written at run time by what ever is in this window.

Cheers, Mike


Did you remove the method-call to 'InitializeComponent' in the constructor of your AboutBox - form ?

Your constructor should at least look like this:

    public partial class AboutBox : Form
    {
        public AboutBox()
        {
            InitializeComponent ();
        }
    }

Where the InitializeComponent method call should be the first line in the constructor.

Tags:

C#

About Box