two questions about screenshots/exports

kemperohlmeyer

Board Regular
Joined
Oct 4, 2006
Messages
73
1) How do i tell vba to cycle through sheets in a workbook? Essentially i need a macro to run through each sheet, export as html (i know that part) and then go to the next sheet and repeat.

2) Each of the aforementioned sheets is very wide (about 80-150 columns). When i export i need the first five columns on the left and then some random (and changing) columns in the middle. It is easy to view with a simple pane freeze, but i don't know how to translate that into an exported view.

Thanks in advance.

ko
 

Excel Facts

Repeat Last Command
Pressing F4 adds dollar signs when editing a formula. When not editing, F4 repeats last command.
1) like this:

Code:
Dim Item as WorkSheet

{code}

for Each Item in ThisWorkbook 'note, any workbook object will work here

  {code}

Next Item

2) Depending upon how you are performing the export, it may be sufficient to Hide the columns that you don't want displayed, perform the export, then unhide them when you are done...
 
Upvote 0

Forum statistics

Threads
1,214,832
Messages
6,121,853
Members
449,051
Latest member
excelquestion515

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