Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Windows Forms
  4. calling other forms

calling other forms

Scheduled Pinned Locked Moved Windows Forms
helpc++question
2 Posts 2 Posters 2 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    Debun
    wrote on last edited by
    #1

    Hello , I have three forms FOrm1 , Form2, Form3 , i want to be able to go back to previous forms from current form . I have called Form1 using Form1->show(); method from Form2, i get error messages stating form1 is an undeclared identifier. If i try to include form1 on form2 , i get series of errors . I'm using the VC++ 2005 can someone help with this?:confused: de

    B 1 Reply Last reply
    0
    • D Debun

      Hello , I have three forms FOrm1 , Form2, Form3 , i want to be able to go back to previous forms from current form . I have called Form1 using Form1->show(); method from Form2, i get error messages stating form1 is an undeclared identifier. If i try to include form1 on form2 , i get series of errors . I'm using the VC++ 2005 can someone help with this?:confused: de

      B Offline
      B Offline
      Blumen
      wrote on last edited by
      #2

      Hi, If you are referring to Windows Forms, you have to create an object of the form before calling it. Example: Create an object of Form1 in Form2 and call objForm1.Show(); But you will get a new instance of that form. If you want to go back and forth like in a web browser, you got to use usercontrols. Just use one form, and load the other forms inside this form. For this you need to have a master form and make usercontrols for other forms. There is a UserControl Class available in .NET controls, you can find it when you try to add a new component from with in a Project. Regards, Blumen

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups