-
I have wriitten a program which is stored in the same folder as the database which it is linked to. However, the address of this folder often changes. Can I set up a 'remote address'(?), to point visual basic to the right folder, without giving it the full address?
-
It'll be helpfull if you use Showopen from commondialog
You can add commondialog to add component with Microsoft Commond dialog.
this is the example of using commondialog SHOWOPEN
Public Sub main11_Click(Index As Integer)
On Error GoTo nodatabase
CommonDialog1.CancelError = True
CommonDialog1.Filter = "*.mdb*"
CommonDialog1.ShowOpen
namafile = CommonDialog1.FileName
If Err = 0 Then
Label1.Caption = CommonDialog1.FileName
Else
MsgBox Err.Description
End If
nodatabase:
On Error GoTo 0
End Sub