c# - Issue connecting to SQL Compact Edition on Windows Mobile 6 Emulator -


I am developing an application for Windows Mobile 6 using an emulator. When I try to open the database connection in the SDF file, it is throwing an exception that it is not able to connect or search the file. My questions are:

  1. Where is the SDF file to be deployed on a mobile device?
  2. When I create the project, the SDF file is automatically positioned on the emulator (such as a windows app) or do I have to do manually?

Any help would be appreciated.

  1. "where" is set by you want you to have it on the emulator, file system In, place your connection at the place of the string. Remember that CE paths are completely qualified.
  2. It depends. How has the SDF been added to your project? If SDF files itself in the project? If so, what is "build action" set (content should be if you want to deploy it)? Is "Copy to Output Directory" set? It should be "always" or "copy if new," if you want to self-deploy it. If you use this mechanism for deployment, the file will end in the same folder as your EXE (or if you have that subfolder int, then this project will be in the subfolder of the deployment directory).

You can use the emulator to access the "Docking" emulator or ActivisSync by using the Emulator Manager to share the file or using the Emulator Manager, using the Remote File Viewer You can deploy the file by default.


Comments

Popular posts from this blog

sql - dynamically varied number of conditions in the 'where' statement using LINQ -

asp.net mvc - Dynamically Generated Ajax.BeginForm -

Debug on symbian -