CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4

Thread: Modeless window

  1. #1
    Join Date
    Oct 2002
    Posts
    359

    Modeless window

    Hi, All,

    I am trying to create a splash window using a modeless window. The dialog template is built as usual and is displayed by calling Show() instead of ShowDialog() as for modal window. The problem is that I cannot see any controls in the modeless dialogbox. I am wondering what is wrong. Presumablly, I forgot to set some properties or initialize some components especially for modeless window?

    Any clue will be appreciated.


    Thanks in advance.

    CR

  2. #2
    Join Date
    Nov 2007
    Location
    .NET 3.5 / VS2008 Developer
    Posts
    624

    Re: Modeless window

    did you change anything in the constructor of the splash form?

    make sure you have this line of code in all form constructors:

    Code:
    InitializeComponent();

  3. #3
    Join Date
    Oct 2002
    Posts
    359

    Re: Modeless window

    Here is the constructor I have:

    InitializeComponent();

    this.FormBorderStyle = FormBorderStyle.None;
    //this.Opacity = 1;
    this.CenterToScreen();
    this.Refresh();

    It does initialize components.

    If I change the method from Show() to ShowDialog(), all the controls apprear as normal.

  4. #4
    Join Date
    Oct 2002
    Posts
    359

    Any help on Re: Modeless window

    Thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured