Is It Possible To Exclude Shapes When Saving Worksheet To HTML Using PublishObjects Method?

CaliKidd

Board Regular
Joined
Feb 16, 2011
Messages
173
I am using Excel 2007 and I have a question when using Excel to save worksheets and charts to a HTML (.htm or .html) webpage via VBA.

I have a worksheet that has some command buttons on it. They are set to not print, but when I save this worksheet as a HTML file, these command buttons are embedded in the HTML code (i.e., they appear). I looked at the HTML source code that the PublishObjects method produced and I found that the command buttons are being converted into .gif files. This is a little annoying because it looks like you can click on these buttons to do something, when in fact, they are just inert images of the buttons themselves.

Is there a way that I can exclude shapes from appearing in the HTML output that Excel's PublishObjects method produces?
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.

Forum statistics

Threads
1,224,574
Messages
6,179,628
Members
452,933
Latest member
patv

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top