Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27355

VS 2010 Loading a form in Windows form similar to "modalPopup" in web

$
0
0
I am loading a "loading" indicator in a separate form named popup, while I have a job running.
This issue is:
The form is blank when it is loaded, I have seen many suggested solutions on web, but none has worked for me.

I am doing like this:
Main form: named MDIParent1

In this I load calc form like this:

Sub setForm(ByVal ActiveForm As Form)
'hideAll()
ActiveForm.MdiParent = Me
ActiveForm.Dock = DockStyle.Fill
'ActiveForm.Location = New Point(100, 100)
ActiveForm.Show()
End Sub

The temp screen, I am trying to load like this:

Code:

Private Sub btnCalc_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCalc.Click
        PopUp.MdiParent = Me
        PopUp.Show()
        Cursor = Cursors.WaitCursor
        calc = True
        Select Case currentForm
            Case "P1"
                PressAlong.Calculate()
            Case "P2"
            Case "H1"
                heatTrad.Calculate()
        End Select
        Cursor = Cursors.Default

        PopUp.Hide()
    End Sub

BUT, the form is blank!!!!
I cant see images or text, just a blank form with bg color.

I have tried bringToFront and many other, but doesnt work :(

Any suggestions???

It seems as it is something with what is on front

Viewing all articles
Browse latest Browse all 27355

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>