|
-
Jun 18th, 2009, 10:07 AM
#1
Thread Starter
Addicted Member
Add New Data Source in Windows Application using C#
Hi Guys,
I am trying to create a windows application using c# connected to a remote sql server database. Unfortunately, everytime I am trying to Add a New Data Source only two options I can choose under Data Source:
Microsoft Access Database File
Microsoft SQL Server Database File
I think Microsoft SQL Server is missing from the list.
If I am going to select Microsoft SQL Server Database File it will only prompt me to open a database file (*.mdf) which is not what I want. I want to connect to an SQL Database from remote server. 
Thanks in advance.
-
Jun 18th, 2009, 10:25 AM
#2
Re: Add New Data Source in Windows Application using C#
Are you using and Express edition by any chance? If so, that's the reason... Express editions will only allow you to connect to local database files using the wizard. It's still possible to connect to remote databases, but you have to do it all form code, losing the ability to manage the connection/database from the IDE.
-tg
-
Jun 18th, 2009, 06:56 PM
#3
Thread Starter
Addicted Member
Re: Add New Data Source in Windows Application using C#
Thanks very much! I am using Express edition. I will try it through codes.
-
Jun 18th, 2009, 07:06 PM
#4
Re: Add New Data Source in Windows Application using C#
One thing you should be able to do is use a local database file to generate your Data Source and then edit the connection string in the config file so that, at run time, a server database is used.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|