Hello,
Sorry I have been searching and can not seem to find what it is I need. I think I have come close but seem to get errors everytime. I am looking to check and see if a network path exists. If it does I want to populate a box. If not, show a message and end the sub. Below is what I have now, but keep getting a bad file name or number error. Any help is greatly appreciated.
Private Sub Form_Load()
Label2.Visible = False
PopulateListControlFromFile List3, "C:\Windows\Path.txt" 'populates list box 3 with the network path to search for IE. \\Cluster1
PopulateListControlFromFile List2, "C:\Appendum.txt" ' populates list box 2 with the information from C:\Appendum.txt
If Dir(List3, vbDirectory) <> "" Then
PopulateListControlFromFile List1, List2 ' populates the list box 1 with the text from List box 2
Else
Label2.Visible = True ' Shows the no connection mecssage
End If
End Sub
Thanks,
Scorpiox
Sorry I have been searching and can not seem to find what it is I need. I think I have come close but seem to get errors everytime. I am looking to check and see if a network path exists. If it does I want to populate a box. If not, show a message and end the sub. Below is what I have now, but keep getting a bad file name or number error. Any help is greatly appreciated.
Private Sub Form_Load()
Label2.Visible = False
PopulateListControlFromFile List3, "C:\Windows\Path.txt" 'populates list box 3 with the network path to search for IE. \\Cluster1
PopulateListControlFromFile List2, "C:\Appendum.txt" ' populates list box 2 with the information from C:\Appendum.txt
If Dir(List3, vbDirectory) <> "" Then
PopulateListControlFromFile List1, List2 ' populates the list box 1 with the text from List box 2
Else
Label2.Visible = True ' Shows the no connection mecssage
End If
End Sub
Thanks,
Scorpiox