Click here to Skip to main content
15,885,216 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have visual studio project. I want to embed myproject.mdf file in to project.
I create tables in my database for development. After I finishe how can ı prepare setup project which include sql stuff?
How can I handle one project with database ?

Forexample , This aplication will installend local user computer.

there is 4 table , table keeps logs.

When user install this software , he can easly save logs. How can I handle database part of project? Can you give me a prerequisites?
Posted
Updated 25-Nov-14 1:01am
v2
Comments
Afzaal Ahmad Zeeshan 25-Nov-14 4:00am    
You need to use the Public options from Visual Studio, they would let you set the dependencies for your project and these would be installed on the client side before he can use the software of yours.
cesimkaol 25-Nov-14 4:11am    
I use sql server 2012 express edition for database.
I want that user have to install to own pc before application installed.
I know ı have to add it to prerequiestes.
I use Linq to SQL (database context) for database part.I dont know how to handle connection strings etc.
Afzaal Ahmad Zeeshan 25-Nov-14 4:13am    
Read this one for connectionstrings. http://connectionstrings.com

1 solution

If there is a need to use database locally, i'd suggest to use SqLite[^] or MS Access[^] database.

If the database have to be shared between users in local area network, you need to choose one computer as a server. Install SQL Server Express on this computer and enable named pipes or ip connections[^] to be able to connect client to the 'centralized' database.


For further information, please see:
Configure a Server to Listen on an Alternate Pipe (SQL Server Configuration Manager)[^]
Configure a Server to Listen on a Specific TCP Port (SQL Server Configuration Manager)[^]
Configure a Windows Firewall for Database Engine Access[^]

ADO.NET Data Providers[^]
Inside SQLite[^]
SQLite's ADO.NET Provider Supports the ADO.NET Entity Framework![^]
Accessing Microsoft Office Data from .NET Applications[^]
How to: Connect to Data in an Access Database[^]
 
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