Results 1 to 4 of 4

Thread: Asynch msg box

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Sep 2001
    Posts
    16

    Asynch msg box

    is there any way (NT/2K) to pop up a message box but continue the application

  2. #2
    Member Dimins's Avatar
    Join Date
    Sep 2001
    Location
    NY
    Posts
    42
    You could designate another form to do that, you can even create a generic AsyncMsgBox Function to do it for you if you'd like.

    1) Add a new form to your Project
    2) Add a Label (named lblMsg for instance)
    3) Add an 'OK' button (named cmdOK if you want)
    4) Set the label caption and then show that form instead of a MsgBox. (this should be done in a generic AsyncMsgBox function)


    just an idea ... hope it helps ...
    -Dimins

  3. #3
    Fanatic Member Patoooey's Avatar
    Join Date
    Aug 2001
    Location
    New Jersey, USA
    Posts
    774
    Try this: Form with 2 commandbuttons, a label and a timer set to 500ms.

    VB Code:
    1. Private Declare Function MessageBox Lib "user32" Alias "MessageBoxA" (ByVal hwnd As _
    2. Long, ByVal lpText As String, ByVal lpCaption As String, ByVal wType As _
    3. Long) As Long
    4.  
    5. Private Sub Command1_Click()
    6. MsgBox "The Timer STOPS!"
    7. End Sub
    8.  
    9. Private Sub Command2_Click()
    10. MessageBox Me.hwnd, "Notice the timer does not stop!", "API Call", vbOKOnly + vbExclamation
    11.  
    12. End Sub
    13.  
    14. Private Sub Timer1_Timer()
    15. Label1.Caption = Time
    16. End Sub

  4. #4
    Member Dimins's Avatar
    Join Date
    Sep 2001
    Location
    NY
    Posts
    42
    Patoooey's way is the way to go ...

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