The following is the code in the module, why can't I login window call? The total error,
The Public Function ExeSQL (ByVal Sql As String) As the ADODB library you
On Error GoTo ErrHandler:
Dim Connstr As String
Dim CN As ADODB. Connection
Dim the rs As the ADODB library you
Dim strArray () As String
Dim DataPath As String
Set the CN=New ADODB. Connection
Set the rs=New ADODB. You
DataPath="PC281453 \ Users \ Data \ Data. The MDB"
Connstr="Provider=Microsoft. Jet. The OLEDB. 4.0. Data Source="+ DataPath +"; Persist Security Info=False "
StrArray=Split (Sql)
CN. Open Connstr
Why Data Source="& amp; App. The Path & amp; Can, the problem is food, but not to the purpose,
CodePudding user response:
Put in DataPath from drive the full path to try, in addition, string concatenation operator is best & amp; Instead, +.CodePudding user response:
If your database is in the exe folder, might as wellDataPath=App. Path & amp; "\ Data. MDB"
If you are quoting is exe folder where a folder path, can
DataPath=App. Path & amp; "\ PC281453 \ Users \ Data \ Data. The MDB"
CodePudding user response: