Is there a way to, If Error then loop back and try again.
This is a live file which is connected to my file and I have it save every
13 seconds but if the live link is saving, it errors out.

'/////////////////////////////////////////////////
Sub UpdateLinks()

ActiveWorkbook.UpdateLink Name:= _
"\\DTCNAS-ILSP002\Tesing\LiveLink.xls" _
, Type:=xlExcelLinks
Range("A1").Select



Call UpdateTime
End Sub


Sub UpdateTime()

Application.OnTime Now + TimeValue("00:00:13"), "UpdateLinks"

End Sub


--
ca1358

Re: if Error, Pause or Loop by fumei

fumei
Thu Nov 29 13:11:20 PST 2007

Why are you posting this in the Word forum?

Seems it would just need some basic On Error error trapping.

ca1358 wrote:
>Is there a way to, If Error then loop back and try again.
>This is a live file which is connected to my file and I have it save every
>13 seconds but if the live link is saving, it errors out.
>
>'/////////////////////////////////////////////////
>Sub UpdateLinks()
>
>ActiveWorkbook.UpdateLink Name:= _
>"\\DTCNAS-ILSP002\Tesing\LiveLink.xls" _
>, Type:=xlExcelLinks
>Range("A1").Select
>
>Call UpdateTime
>End Sub
>
>Sub UpdateTime()
>
>Application.OnTime Now + TimeValue("00:00:13"), "UpdateLinks"
>
>End Sub
>

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.aspx/word-programming/200711/1