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

Thread: Add a form

  1. #1
    Join Date
    Apr 1999
    Posts
    74

    Add a form

    I want to add 4 forms to my SDI app. I first thought I could use the dialog editor & then create a class to support the form (deriving from CFormView.

    When you right-click on your project classes in ClassView, there is an Add Form option? Do I use this in addition to the above, or instead of ? I can't seem to find much explanation on the steps to take to add several forms to an app. Will greatly appreciate any comments or s****. Thanks. JD


  2. #2
    Guest

    Re: Add a form

    If you have a class for your form. you must declare an object of this class
    exemple for a CDialog derivated class

    COtherDlg clOther(); //i don't know if it take parameters

    // Initialistation of member variable of the class
    clOther.m_variable =123;

    //Display the dialogbox
    clOther.DoModal();

    m_MainVar =clOther.m_variable;

    I hope it help
    Marc
    Industrial Software Developer


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