locked
Binding a local mdb (MSAccess) file to Windows 8.1 app - VB

    Question

  • Can anyone please help me? I have been spoiled by the WPF interface of binding ole db (MS Access mdb) database files to my apps but I am now lost how to proceed with the Windows 8 apps XAML/VB. I can easily add a data connection from the database explorer but going further I am simply stuck. True enough I am a newbie, but I cannot seem to figure this out on my own. Can anyone offer me step-by-step instructions how to achieve this? So I have a local mdb database file (OLE DB) and I am attempting to display specific data into either a textbox, grid, or another such output control. After I add the data source, how should I proceed?

    Thank you,

    Eddie

    Wednesday, May 7, 2014 8:01 PM

Answers

All replies

  • Hi,

    You cannot direct connect ole db in windows store app. If you want to talk to a ole db you're going to need to use some kind of other protocol (WebService, SOAP, WCF, etc.). If you want to talk to local database,I recommend you can use SQLite Database in windows store app. You can refer to the links in the below:

    http://msdn.microsoft.com/en-us/library/windows/apps/dn263243.aspx

    http://blogs.msdn.com/b/robertgreen/archive/2012/11/13/using-sqlite-in-windows-store-apps.aspx

    And see the sample:

    http://code.msdn.microsoft.com/windowsapps/Using-SQLite-and-sqlite-79efa172

    http://code.msdn.microsoft.com/windowsapps/Sqlite-For-Windows-8-Metro-2ec7a882

    Best Wishes!


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey. Thanks<br/> MSDN Community Support<br/> <br/> Please remember to &quot;Mark as Answer&quot; the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Thursday, May 8, 2014 3:19 AM
  • Thank you for your answer and the links. I've been down that road before and quite honestly the SQLite step-by-step guide has some faulty lines of code. I tried it and since I was rather untrained on C#, I could not make it work at all. Are there any VB.net versions of the SQLite guide? I looked all over and for lack of finding anything concise I gave up on SQLite altogether. I really would have loved to use SQLite due to its standalone capability (not needing a server side support) but lately implementing it with windows has become quite a painful process. And I've been down some painful roads with other APIs but not when I had to muddle through a language I have not quite well mastered. But your response does save me the headache of searching for a binding to and OLE db. I hope that if I give SQLite one more shot I can make it work. But am not exactly very hopeful. Have you had any luck with it?

    Eddie

    Thursday, May 8, 2014 7:16 AM
  • Hi,

    VB and C# are extremely similar.You should be able to read the C# and make the adjustments as they use the exact same objects. In MSDN, there is no VB sample about SQLite.  If you have further questions about SQL Lite, please ask them on the SQL lite forums.

    Best Wishes!


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey. Thanks<br/> MSDN Community Support<br/> <br/> Please remember to &quot;Mark as Answer&quot; the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Thursday, May 8, 2014 7:32 AM
  • Thank you, I will give SQLite another shot this weekend with C#. 

    Thank you. 

    Thursday, May 8, 2014 4:46 PM