macro to save current excel sheet only without losing formatting

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a macro that saves the current worksheet only (fileformat=xlNormal),
and automatically generates a new filename, but formatting is lost, so
reprinting the sheet looks completely different from the original.
 
What file exttension are you saving XLS or CSV? CSV will not save the
formatting. I think your problem is the file extension you are using.
 
this is just a guess:
Activeworkbook.SaveAs "C:\Mybook", fileformat:=xlNormal

note the colon before the equal sign.

If I don't have the colon, I get an error, but perhaps for you it saves it
as some kind of text file.
 

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

Back
Top