Click here to Skip to main content
15,896,278 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
Suppose I have a database on localhost. I want to connect a C# application with it.
I want to just put database file local to that application and it pick it up from there each time. I don't need to give database path.
Application: myapplication.exe
Database: file.mdf and file_log.ldf. etc

Please a connection string solution.
Thanks
Posted
Comments
Sergey Alexandrovich Kryukov 9-Jan-13 16:50pm    
Where is your question?
—SA

1 solution

No It wont work. .mdf and .ldf are SQL Server files you cannot interact directly with these files without SQL Server Engine.

Also check this[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900