CodePudding user response:
Sub demo ()
Application. The OnTime TimeValue (" 15:00:00 "), "the button click event process name"
End Sub
CodePudding user response:
Tried the following two statements, in the thisworkbook or new modules are not, to the time no response, I don't know where the problem is,Sub demo ()
Application. The OnTime TimeValue (" 20:28:00 "), "CommandButton1_Click ()", "
End Sub
Sub demo ()
Application. The OnTime TimeValue (" 20:18:00 "), "ThisWorkbook. Sheets (" Sheet1"). CommandButton1_Click "
End Sub
CodePudding user response:
The code migration on a mission to another module named RunX, assume the process in the button click event call RunX below, is also specified in ontime RunX tryGenerally not recommended directly write functional code in the event of a button