Consulting

Results 1 to 6 of 6

Thread: pause and continue

  1. #1
    VBAX Contributor
    Joined
    Apr 2012
    Posts
    107
    Location

    pause and continue

    macro to continue after 5 min or I hit Enter key
    plse add code
    [VBA]' Waits 5 min
    Application.Wait Time + TimeSerial(0, 5, 0)
    ' Continues here after pause[/VBA]

  2. #2
    Knowledge Base Approver VBAX Guru GTO's Avatar
    Joined
    Sep 2008
    Posts
    3,368
    Location
    [VBA]Option Explicit

    Sub macroWait()
    MsgBox "Wait"
    Application.Wait Now + TimeValue("00:00:05")
    MsgBox "Go"
    End Sub[/VBA]

  3. #3
    VBAX Contributor
    Joined
    Apr 2012
    Posts
    107
    Location
    Thank you for your code.
    my vba is:
    a
    b
    c
    d
    if I want to wait after b and continue after c, what code to add between b and c,plse?

  4. #4
    Distinguished Lord of VBAX VBAX Grand Master Bob Phillips's Avatar
    Joined
    Apr 2005
    Posts
    25,453
    Location
    a
    b
    Call MacroWait
    c
    d
    ____________________________________________
    Nihil simul inventum est et perfectum

    Abusus non tollit usum

    Last night I dreamed of a small consolation enjoyed only by the blind: Nobody knows the trouble I've not seen!
    James Thurber

  5. #5
    VBAX Contributor
    Joined
    Apr 2012
    Posts
    107
    Location
    Thank you for your help.

  6. #6
    VBAX Regular
    Joined
    May 2012
    Location
    London, United Kingdom
    Posts
    6
    Location

    Procedure calling wherever we want to call

    In your question I am not getting you want position of call or saying a,b,c character checking so I am replying both.
    first: when we have to call any code according to our desire we could type our code in procedure and call it wherever we want to call.

    second: you could check ASCII value of a b c characters and call your procedure.

    I hope you would get your answer.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •