Avatar of Joe Rud
Joe Rud
Flag for United States of America asked on

Excel 2010 Autosave (not AutoRecover)

Good day to you Experts!

I'm in the search of a way to make Excel 2010 do an auto-save.  The built-in autorecover function is different and not what I need.

The functionality I'm looking for is to make Excel save the current document every X minutes, just as though I were to click the save icon / Ctrl+S / etc.  I know this functionality is not built-in (at least I'm led to believe that anyway).  Any 3rd party add-ons that do this?

BTW - my motivations are not my own.  I was tasked by my manager to find this.

Thanks to all.
Microsoft ExcelMicrosoft ApplicationsMicrosoft Office

Avatar of undefined
Last Comment
dlmille

8/22/2022 - Mon
csoussan

Per Gord Dibben (http://www.pcreview.co.uk/forums/there-auto-save-office-2007-excel-t3437008.html):

Jan Karel Pieterse has an addin called AutoSafe
which doen't alert before saving.

http://www.jkp-ads.com/download.asp

(look for AutoSafe.zip)

It doesn't overwrite the existing workbook when it saves. It saves to a user
selectable folder. And when it's done, it either deletes these backups (or
puts them in the recycle bin). And the user can always restore the backups
from the recycle bin.

Hope that helps.
Joe Rud

ASKER
Csoussan - that utility creates a copy in another location, which is not what I want.  I'm looking for something that is exactly like saving the file (an overwrite, if you prefer) - just automates it at a set interval.
ASKER CERTIFIED SOLUTION
csoussan

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Joe Rud

ASKER
Would you believe me if I told you that I have a copy of Office 97 readily available?  I'm looking into that autosave.xla file.  Thanks.
Your help has saved me hundreds of hours of internet surfing.
fblack61
dlmille

If the autosave.xla doesn't work for you, here's one I wrote.  You can load the file and check out the menu options in your Add-Ins menu, re: AutoSave!.  If you like it, you can save as a .xla then install it as a permanent addition to your Excel add-ins.

You can toggle the startup state (either always on, or off), you can initialize (restarts the timer) and you can set parameters (simple 1-60 minute autosave interval).

Primarily at the appropriate time, events, screen updating, and displayalerts are turned off, all workbooks are saved, then events, screen updating, and displayalerts are turned bck on.

Here's the primary code:
Option Explicit
Public runWhen As Double
Sub AutoSave_Parameters(Optional AutoSaveInterval As Variant = 10)
'Dim AutoSaveInterval As Variant
Dim bProceed As Boolean
Dim currMins As Variant

    currMins = Evaluate("'" & ThisWorkbook.Name & "'!AutoSaveInterval")
        
    If IsError(currMins) Then currMins = 10
    
    AutoSaveInterval = InputBox("Please Enter AutoSave Interval in Whole Minutes (1-60): ", Default:=currMins)
    
    'simple validation, bail on error
    If Not AutoSaveInterval = vbNullString And IsNumeric(AutoSaveInterval) Then
        bProceed = True
        If (CInt(AutoSaveInterval) <= 0 Or CInt(AutoSaveInterval) > 60) Then bProceed = False
    End If
    If Not bProceed Then
        MsgBox "Invalid input:  Number must be between 1 and 60", vbCritical, "Try Again!"
    Else
        ThisWorkbook.Names.Add Name:="AutoSaveInterval", RefersTo:=AutoSaveInterval
        Call deAutoSave_Initialize(False)
        Call AutoSave_Initialize(True)
    End If
    
End Sub
Public Sub AutoSave_Initialize(Optional bPrompt As Boolean = False)
Dim AutoSaveInterval As Variant

    AutoSaveInterval = Evaluate("'" & ThisWorkbook.Name & "'!AutoSaveInterval")

    If IsError(AutoSaveInterval) Then
        MsgBox "You Must Set AutoSave Interval, First"
    Else
        runWhen = Now() + TimeValue("00:" & AutoSaveInterval & ":00")
        Application.OnTime runWhen, "AutoSave_Now", schedule:=True
        If bPrompt Then MsgBox "AutoSave Initialized at: " & AutoSaveInterval & " mins."
    End If
End Sub
Public Sub deAutoSave_Initialize(Optional bPrompt = True)
    On Error Resume Next
    Application.OnTime earliesttime:=runWhen, procedure:="AutoSave_Now", schedule:=False
    On Error GoTo 0
    If bPrompt Then MsgBox "AutoSave Paused"
End Sub
Sub autoSave_Now()
Dim wkb As Workbook
    
    Application.EnableEvents = False
    Application.DisplayAlerts = False
    Application.ScreenUpdating = False
    
    For Each wkb In Application.Workbooks
        Application.StatusBar = "Saving: " & wkb.Name & " ..."
        On Error Resume Next
        wkb.Save
        On Error GoTo 0
    Next wkb
    
    Call AutoSave_Initialize
    
    Application.StatusBar = False
    Application.ScreenUpdating = True
    Application.DisplayAlerts = True
    Application.EnableEvents = True
End Sub

Open in new window


See attached.

Cheers,

Dave
autosave-r1.xls
csoussan

Hi Geisrud,

Any update on your issue?
Joe Rud

ASKER
As far as I can tell, this method works perfectly.  I didn't have the 10 minute limitation described either.  I tested by setting this to 1 minute, and autosave worked as I wanted - either with or without prompts.
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
dlmille

I'm curious. Did you try my solution?