ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Publish an Excel 2003 Chart to HTML file (https://www.excelbanter.com/excel-programming/384370-publish-excel-2003-chart-html-file.html)

[email protected]

Publish an Excel 2003 Chart to HTML file
 
Please can someone help publish my Excel chart to an HTML file using a
macro. I found the code:

With ActiveWorkbook.PublishObjects.Add(SourceType:=xlSo urceChart,
_
Filename:="C:\Work.htm", Sheet:="Chart1", Source:="Chart 1",
_
HtmlType:=xlHtmlStatic, DivID:="Chart1_04")
.Publish (True)
End With

But it does not work, I receive the error "Compile error: Expected
Function or variable".

Can anyone help?

Thanks,

Brett



All times are GMT +1. The time now is 02:10 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com