Public Sub ConnectDB()
On Error Resume Next: Err.Clear
If DB.State = adStateOpen Then Exit Sub
DB.Close
MyPath = App.Path
If Right(MyPath, 1) <> "\" Then MyPath = MyPath & "\"
DBPathName = MyPath & "sample100.mdb"
DB.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & DBPathName
DoEvents
end sub
'اين اعمل باسسورد للفيجوال بيسك للدخول عبر الاكسس
طبعا الاكسس له رقم سري واريد الاتصال به ورقم السري هو 123321
On Error Resume Next: Err.Clear
If DB.State = adStateOpen Then Exit Sub
DB.Close
MyPath = App.Path
If Right(MyPath, 1) <> "\" Then MyPath = MyPath & "\"
DBPathName = MyPath & "sample100.mdb"
DB.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & DBPathName
DoEvents
end sub
'اين اعمل باسسورد للفيجوال بيسك للدخول عبر الاكسس
طبعا الاكسس له رقم سري واريد الاتصال به ورقم السري هو 123321