I'm having an error when looking at the demo app. Am unable to connect to the mdf. The following error is being raised in the browser when attempting to use any of the controls that are connected to the database:
Could not open new database 'D:\DOCUMENTS AND SETTINGS\ALL USERS\DOCUMENTS\DXPERIENCE 12.1 DEMOS\ASP.NET\MVC\CS\MVCDEMOS\APP_DATA\NWIND.MDF'. CREATE DATABASE is aborted.
An attempt to attach an auto-named database for file D:\Documents and Settings\All Users\Documents\DXperience 12.1 Demos\ASP.NET\MVC\CS\MVCDemos\App_Data\NWind.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.
File activation failure. The physical file name "D:\Documents and Settings\All Users\Documents\DXperience 12.1 Demos\ASP.NET\MVC\CS\MVCDemos\App_Data\NWind_log.ldf" may be incorrect.
The log cannot be rebuilt when the primary file is read-only.
Thank you for contacting us. To run the demos of the DevExpress ASP.NET components locally on your computer, you should have one of the following versions of Microsoft SQL Express installed:
- Microsoft SQL Server 2005 Express Edition (SP3);
- Microsoft SQL Server 2008 Express Edition (SP1).
This requirement is imposed because our demos use locally deployed .mdf files as data sources.
If you have a greater edition of the SQL Server , it is simply necessary to re-configure the connection string in the Web.config file accordingly:
- Remove the "\SQLEXPRESS" postfix from the server name;
- Remove the "User Instance=true" key/value pair.
<add ...connectionString="data source=.;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;" providerName="System.Data.SqlClient" />