A recorded Macro to hide certain selected columns hides non selec.

G

Guest

I have recorded a macro to hide certain columns (E, F, G, L, N, O, P, Q,
S:AA) in a spreadsheet which when I do it manually works fine. When I run
the the macro it hides everything from B to AA. Why? How can I fix this. I
have tried just hiding one column with the macro and it still hides them all.
The Spreadsheet has merged columns, but that does not seem to be a problem
when done manually.
 
D

Dave Peterson

with worksheets("sheet1")
.range("e:g,l:l,n:q,s:aa").entirecolumn.hidden = true
end with

If this doesn't help, you may want to post your code.
 
B

Bob Phillips

If you post the code it might help.

--

HTH

RP
(remove nothere from the email address if mailing direct)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top