save to two locations in word and powerpoint

S

Shasur

Hi

Here is the modified one for powerpoint

Sub SaveBackUpFile_PPT()

Dim strFileA As String
Dim strFileB As String
Dim strFileC As String

Application.DisplayAlerts = False
ActivePresentation.Save
strFileA = ActivePresentation.Name

'Define backup path shown in blue below

strFileB = "c:\temp\Backups\" & strFileA
strFileC = ActivePresentation.FullName

ActivePresentation.SaveAs FileName:=strFileB
ActivePresentation.SaveAs FileName:=strFileC

Application.DisplayAlerts = True

End Sub


and the one below cane be used for Excel

Sub SaveBackUpFile_Excel()

Dim strFileA As String
Dim strFileB As String
Dim strFileC As String

Application.DisplayAlerts = False
ActiveWorkbook.Save
strFileA = ActiveWorkbook.name

'Define backup path shown in blue below

strFileB = "c:\temp\Backups\" & strFileA
strFileC = ActiveWorkbook.FullName

ActiveWorkbook.SaveAs Filename:=strFileB
ActiveWorkbook.SaveAs Filename:=strFileC

Application.DisplayAlerts = True

End Sub


Cheers
 

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