repost from v8 forum excel.application.ontimer "cannot run macro"

>I am using the "Application.ontimer" member of the excel library  to call a Public Sub GetTime()

>I am getting the error "Cannot run the Macro "GetTime" May not be available in this  workbook or all...."

>I've changed my security setting to "none" in Microstation XM, is there a place where I should look to see if macros are disabled?  I am running other vba, with no >problem.

The security setting that I changed is in the Microstation environment, under Workspace-Security

I add a clock to a vba form in Excel using the application.ontimer like:

  Public Sub  GetTime()

    Dim ID As Date

    UFClock.clock =Format(Now, "mm/dd/yy hh:mm:ss")

    ID = Now +TimeValue("00:00:0001")

    UFClock.LastTime= ID

    Application.OnTime ID, "GetTime"

End Sub

I wanted to do the same in microstation, but there isn't the Application.ontimer  so I loaded the excel library and used excel.application.ontimer but it won't launch the "gettime"  I've also tried "ufclock.gettime" .

I have the gettime in a module, but I've also tried it in the form programming as a private function.

any help is greatly appreciated.

 

Parents Reply Children
No Data