View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Kashyap Kashyap is offline
external usenet poster
 
Posts: 131
Default Dynamic drive selection to update link

I have the below code live.. but can I have a code that search in drive F, G,
H if this path does not exist?

That is it should search in
"F:\Primary\Master-May.xls", _
"G:\Primary\Master-May.xls", _
"H:\Primary\Master-May.xls", _

Sub ref()

ActiveWorkbook.UpdateLink Name:= _
"E:\Primary\Master-May.xls", _
Type:=xlExcelLinks

End Sub