• 0

[VB 6] How to get a new form


Question

Hi. I am using vb6 and I was wondering if there is a way when I click on a cmd button that I could get a new form. For example, if form1 has 9 buttons on them if I clicked on the first button then it would close the current form (form1) and bring up another form, for example form2... and each different button will open a new form. And if there is another possible better way to create something like this I am willing to hear other suggestions. Thanks! :ninja:

Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0
thanks winston but how do i put the new forms in focus?

584805057[/snapback]

hmmm frmName.setFocus, i'm pretty sure that's it, haven't used VB6 in ages

Link to comment
Share on other sites

  • 0

To make the new form appear in focus with VB6, you can do:

formname.show VbModal

Or if you want it to close the first form and load the second, you can do:

Unload Me
Form2.Show vbModal

Edited by petroid
Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.