代码:
Sub test()MsgBox ("test")
Application.OnTime Now + TimeValue("00:00:03"), "test"End Sub错误信息:
The macro "D:\***.xls'!test' cannot be found.

解决方案 »

  1.   

    Private Sub test()
    MsgBox ("test2")
    Application.OnTime Now + TimeValue("00:00:03"), "THISWORKBOOK.test"
    End Sub你的程序没什么大错,只是没有写明test属于那个对象。我给你加了HISWORKBOOK,如果你的STET程序是写在sheet1里面的,就要改成"sheet1.test",这样就不会报找不到过程了。有机会可以加48029944VB群,进一步探讨。