64-bit Issues


While testing the example programs for this chapter on my new 64-bit computer, I discovered that the programs looked fine, but didn’t load any data. I could even preview the data in design mode, but when I ran the programs, they worked, but didn’t load any data.

What happened was my computer didn’t have a 64-bit driver installed for the Jet database engine (right now, there is no 64-bit driver for the Jet engine). When a program tries to open a Microsoft Access database, the engine displays an InvalidOperationException message in the Immediate window and then continues as if it had successfully opened the database. The program seems to work, but with no data.

To work around this issue, open Solution Explorer and double-click the application’s My Project entry. Select the Compile tab and click the Advanced Compile Options button to display the dialog box shown in Figure 11-1. In the Target CPU drop-down at the bottom, select x86 and click OK. Now the application will use the 32-bit Jet drivers instead of looking for 64-bit versions.

image from book
Figure 11-1: When using Microsoft Access databases on 64-bit computers, set the target CPU to x86.




Visual Basic 2005 with  .NET 3.0 Programmer's Reference
Visual Basic 2005 with .NET 3.0 Programmer's Reference
ISBN: 470137053
EAN: N/A
Year: 2007
Pages: 417

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net