i think you can just try to open a recordset based on linked table - if you
get an error - then path does not exists, so you need to relink table
--
Alex Dybenko (MVP)
http://Alex.Dybenko.com
http://www.PointLtd.com
"Bruce" <(E-Mail Removed)> wrote in message
news:37025C68-46F3-408E-A8CD-(E-Mail Removed)...
> My Database has some linked tables on another server. How can I check that
> the server is available before 'running my other codes'?
>
> Using the example below I can check a folder but really in this case I
> just
> need to check the servername which does not work if I have varPath =
> "\\myServer"
>
> Is their a function to check the computername?
> Should I verify the linked table connection another way?
>
> Bruce
>
> Sub test()
> varPath = "\\myServer\Groups\Market"
> MsgBox (FolderExists(varPath))
> End Sub
>
> Public Function FolderExists(varPath As Variant) As Boolean
> On Error Resume Next
> If Len(varPath) > 0& Then
> FolderExists = (Len(Dir$(varPath, vbDirectory)) > 0&)
> End If
> End Function
>
>