Auto-Save

Nomis_Eswod

Board Regular
Joined
Jul 27, 2005
Messages
153
Hi,

I have a workbook, and Auto-Save added as an add-in. But, the workbook is to be used by people who potentially won't have that add-in. Is there anyway to write some code so that the sheet auto-saves every 5 minutes??

Many thanks in advance.
 

Some videos you may like

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand

Barrie Davidson

MrExcel MVP
Joined
Feb 10, 2002
Messages
2,330
Code:
Option Explicit

Sub Auto_Save_Timer()
Application.OnTime Now + TimeValue("00:05:00"), "Auto_Save"
End Sub
Sub Auto_Save()
ThisWorkbook.Save
Auto_Save_Timer
End Sub

Of course, this will be negated if the user doesn't enable macros.

Best regards,
 

lenze

Legend
Joined
Feb 18, 2002
Messages
13,690
You can write an On Open Event that checks for the add-in and if not found, installs it. Unfortunately, the machine I'm on now doesn't have Excel, so I can't check the nomenclature for you now, but it is something like

If Application.AddIns("Auto Save").Installed = False Then
Application.AddIns("Auto Save").Installed = True

Perhaps someone else can check it out, or see the vba help files

lenze
 

Nomis_Eswod

Board Regular
Joined
Jul 27, 2005
Messages
153
Many thanks for this.

once I have started this, will it just continue to run?? I.e. if I put it in Workbook open will it then just continue to run??
 

Watch MrExcel Video

Forum statistics

Threads
1,118,521
Messages
5,572,630
Members
412,475
Latest member
JaredNAU
Top