Connecting to an .sdf database on a mobile device

Jun 23, 2014 at 9:06 PM

I've got RAPI2 up and working. I'm copying files, etc. However, I'm still a little stuck as to how I would connect to a .sdf database saved on a Windows Mobile 6.5 device from a PC.

For reference, I've been using "System.Data.SqlServerCe" in a C# application to manipulate .sdf databases. That works great, too. But it requires a full path (with drive letter) for connectivity. Naturally, this doesn't adapt well to the mobile device world.

I've read online that a lot of people just make local copy (using RAPI2) of the mobile device's .sdf database, manipulate it on the PC, and copy back. But, that won't work in my situation. The database file I need to access is in use on the mobile device. So, a copy/replace gives a bunch of errors.

Any ideas? Is there a way to resolve a path to the database file on the mobile device that's utilizable by the PC? How does this normally work?

Thanks for your help.