On Vista 32bit and Windows 7 I get the following error using the AccessProvider trying to open the access database file.
"[Microsoft][ODBC Microsoft Access Driver]Invalid string or buffer length"
To recreate the problem do the following while running Vista 32 bit or Windows 7 RTM 32 bit.
UniConnection1.ProviderName:= 'ACCESS';
UniConnection1.Database:= 'C:\myapp\mydatabase.mdb';
UniConnection1.Connect;
This was testing with a clean VM of Windows 7 RTM. This same code works on Windows XP Pro SP3.
Access Provider Error in Vista and Windows 7
-
- Posts: 22
- Joined: Thu 10 Sep 2009 16:18
- Location: United States
-
- Posts: 22
- Joined: Thu 10 Sep 2009 16:18
- Location: United States
Access Provider Error in Vista and Windows 7
Great, glad you found the issue. Now, we need this fix ASAP. Can we get a pre-release build, updated source code or at least instructions on where to fix this in the source we purchased? We hit a brick wall with this issue on our ms access database version and cannot wait a month or more for a major fix like this to continue testing. Our Vista and Win 7 testers cannot connect to the database at all because of this issue.
Thanks
Thanks
Find the TODBCConnection.ObtainDriverInfo procedure in ODBCClasses.pas.
Replace the line
with
Replace the line
Code: Select all
Check(FCli.SQLGetInfoInt(FSQLHDbc, SQL_IDENTIFIER_CASE, Val, 0, nil));
Code: Select all
Check(FCli.SQLGetInfoInt(FSQLHDbc, SQL_IDENTIFIER_CASE, Val, 4, nil));