Hello.
I've grabbed the following code from a tutorial on DevX (http://
www.devx.com/webdev/Article/10172) to periodically publish chart data
to a live webpage.
Sub Auto_Open()
ActiveWorkbook.PublishObjects.Add(xlSourceChart, _
"X:\charts\ResponseDist.htm" _
, "Chart1", "", xlHtmlStatic, "DevXSample_16365", _
"").Publish (True)
Application.OnTime Now + TimeValue("00:05:00"), _
"Auto_Open"
End Sub
The macro works fine the first time I run it from the
VB Editor, but
fails on subsequent time with "The macro 'C:\Documents and Settings
\Chris\My Documents\ChartUpdate2.xls'!Auto_Open' cannot be found."
I've tried locating the code in the Chart, Sheet and Workbook modules
without luck.
Can anyone see where I'm going wrong?