Mulitble forms in VB

K

Karsten_Markmann

HI. I am currently converting a VBA application to VB .Net 3003 (Com
addin).
I have several foms which I call from the main module.
In VBA code execution stops until the form is closed but in my VB .Net
application the code in the main application continues executing even
if a form is open.

I have the following code:

Dim frmsearchdeb As New frmSearchDebitor
Dim frmtest As New frmDokumentskabeloner

frmsearchdeb.Show()
MsgBox("venter ikke på dialog lukning")
frmtest.Show()

I dont want frmtest to be shown before the user exits the frmsearchdeb
form.
I dont get it why this doesn't work in VB???

All help appriciated. Kind regards Karsten.
 
A

Armin Zingler

Karsten_Markmann said:
HI. I am currently converting a VBA application to VB .Net 3003 (Com
addin).
I have several foms which I call from the main module.
In VBA code execution stops until the form is closed but in my VB
.Net application the code in the main application continues
executing even if a form is open.

I have the following code:

Dim frmsearchdeb As New frmSearchDebitor
Dim frmtest As New frmDokumentskabeloner

frmsearchdeb.Show()
MsgBox("venter ikke på dialog lukning")
frmtest.Show()

I dont want frmtest to be shown before the user exits the
frmsearchdeb form.
I dont get it why this doesn't work in VB???

All help appriciated. Kind regards Karsten.

Show shows the Form modeless. Use ShowDialog to show it modally.


Armin
 
K

Karsten_Markmann

Show shows the Form modeless. Use ShowDialog to show it modally.

Armin- Skjul tekst i anførselstegn -

- Vis tekst i anførselstegn -

Thanks Armin.
I had complete starred me blind into this issue. :)
thanks again.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top