![]() |
Setting up autorecovery problems
I am trying to forcefully set the autorecovery option to True for a
particular workbook. I've set the path for recovery, but when I call my function it keeps stalling at my with statement "With Application.AutoRecover" The big problem is I cannot find much in the way of help online for autorecovery. Sub SetAutoRecoverOptions() 'Set the AutoRecover options for the application ChangeAutoRecoverSettings True, "\\CCT75-F3-FIL03\GLOBALSHARE01\PMD PMO\F05 Files\Monthly-Project LE\02+10 Post Act Projects\Project over $1MM\CIS\", 2 'Make sure this workbook uses them ActiveWorkbook.EnableAutoRecover = True End Sub Function ChangeAutoRecoverSettings(Optional ByVal vEnable As Variant, Optional ByVal vPath As Variant, Optional ByVal vTime As Variant) With Application.AutoRecover 'Only set the property if a value was passed If Not IsMissing(vEnable) Then 'Enable AutoRecover .Enabled = vEnable End If 'Only set the property if a value was passed If Not IsMissing(vPath) Then 'Change the path to a central backup files area .Path = vPath End If 'Only set the property if a value was passed If Not IsMissing(vTime) Then 'Save every AutoRecover file every 2 minutes .Time = vTime End If End With End Function |
Setting up autorecovery problems
DUH!!!!
Excel 2000 does not have the option for Autorecovery, hence the problems with my script. I use 2003 at home and 2000 at work . . . .. "Jeff" wrote: I am trying to forcefully set the autorecovery option to True for a particular workbook. I've set the path for recovery, but when I call my function it keeps stalling at my with statement "With Application.AutoRecover" The big problem is I cannot find much in the way of help online for autorecovery. Sub SetAutoRecoverOptions() 'Set the AutoRecover options for the application ChangeAutoRecoverSettings True, "\\CCT75-F3-FIL03\GLOBALSHARE01\PMD PMO\F05 Files\Monthly-Project LE\02+10 Post Act Projects\Project over $1MM\CIS\", 2 'Make sure this workbook uses them ActiveWorkbook.EnableAutoRecover = True End Sub Function ChangeAutoRecoverSettings(Optional ByVal vEnable As Variant, Optional ByVal vPath As Variant, Optional ByVal vTime As Variant) With Application.AutoRecover 'Only set the property if a value was passed If Not IsMissing(vEnable) Then 'Enable AutoRecover .Enabled = vEnable End If 'Only set the property if a value was passed If Not IsMissing(vPath) Then 'Change the path to a central backup files area .Path = vPath End If 'Only set the property if a value was passed If Not IsMissing(vTime) Then 'Save every AutoRecover file every 2 minutes .Time = vTime End If End With End Function |
All times are GMT +1. The time now is 10:37 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com