Is there an equivalent to Thread.Sleep() in VBA

后端 未结 8 1288
孤街浪徒
孤街浪徒 2020-12-01 13:38

Is there an equivalent to Thread.Sleep() in Access VBA?

8条回答
  •  南笙
    南笙 (楼主)
    2020-12-01 14:16

    It is possible to use the Excel Wait() procedure from Access VBA.

    The first step is to ensure that the Excel library is referenced from your project.

    When that's done the following code will work to wait for ten seconds :

    Call Excel.Application.Wait(Time:=DateAdd("s",10,Now()))
    

提交回复
热议问题