Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
messi
Starting Member
47 Posts |
Posted - 2009-07-15 : 12:25:10
|
i am having a connection problem my connection like: but when i run my pro he gives me this msg:"Illegal characters in path"i am using c# 2008 expresssql server 2008 express tooany one help |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-07-15 : 12:35:01
|
| seehttp://www.connectionstrings.com/sql-server-2008 |
 |
|
|
afrika
Master Smack Fu Yak Hacker
2706 Posts |
Posted - 2009-07-15 : 13:03:05
|
Hi Messi,in c# you either replace all backslashes \ with double back slashes \\ or You put an @ sign at the start of your connection stringThis is the default in c# However i would advice you put your connection string in your web.config file and reference it as a variable in your classeshere is an example<connectionStrings> <add name="afrika" connectionString="Data Source='michaeljackson';Network Library=DBMSSOCN;Initial Catalog=mydatabase;User ID='username';Password='password';" providerName="System.Data.SqlClient" /> </connectionStrings> |
 |
|
|
messi
Starting Member
47 Posts |
Posted - 2009-07-16 : 01:14:36
|
| thanks for replying and help visakh16and thanks afrika but i am using windows forms not web |
 |
|
|
afrika
Master Smack Fu Yak Hacker
2706 Posts |
Posted - 2009-07-16 : 15:58:14
|
| Oh.well c# is c#I have a book on winforms but never really got into it. Use the double slashes or the @ at the start |
 |
|
|
|
|
|