ActiveSheet.Copy
On Error Resume Next
MkDir "C:\Documents and Settings\bob\Desktop\statistics"
On Error GoTo 0
ActiveWorkbook.SaveAs "C:\Documents and
Settings\bob\Desktop\statistics\" & ActiveSheet.Name
change the location to suit
--
HTH
Bob Phillips
(remove xxx from email address if mailing direct)
"Simon Lloyd"
wrote in message
...
Hi all,
Can anyone tell me how in vba to save a single worksheet as the
worksheets name in a new folder called statistics on the desktop or in
my documents but if the folder does not exist create it first?
Rather than save all my statistic worksheets in the workbook they were
generated in i would like to save them as a read only worksheet in
another folder, this way people can view or copy from an area where
they can have no direct influence on the workbook that created them.
Any ideas?
Regards,
Simon
--
Simon Lloyd
------------------------------------------------------------------------
Simon Lloyd's Profile:
http://www.excelforum.com/member.php...fo&userid=6708
View this thread: http://www.excelforum.com/showthread...hreadid=542456