Trouble with WAIT and OLE link updates

Bigzippy

Board Regular
Joined
Jul 1, 2003
Messages
182
Hey-
I have this code that updates links from another program, it takes about 15-18 seconds to update and recalc(?). application.wait does not help. the problem is that the values that are updating show #N/A until they are done updating so my formula copies "#N/A" (BTW i need to copy value only )if it moves to next routine befor update is complete-Please Help I have looked for and tried many ideas, but i must be missing something.

Thanks!

Sub linkupdate2()
Dim alinks As Variant
Dim i As Variant
alinks = ActiveWorkbook.LinkSources(xlOLELinks)
If Not IsEmpty(alinks) Then
For i = 1 To UBound(alinks)
ActiveWorkbook.UpdateLink Name:=alinks(i), Type:=xlLinkTypeOLELinks
Next i
End If
End Sub
 

Excel Facts

Select all contiguous cells
Pressing Ctrl+* (asterisk) will select the "current region" - all contiguous cells in all directions.

Forum statistics

Threads
1,214,378
Messages
6,119,188
Members
448,873
Latest member
jacksonashleigh99

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top