problems with Configuration manager  
Author Message
dan59





PostPosted: Visual Basic Express Edition, problems with Configuration manager Top

Sorry for this newbi question. I'm using vbexpress and trying to connect to a database file call 'medical.mdf'.

I continue to get the error message'ConnectionStrings is not a member of medical3.ConfigurationManager'. The project name is 'medical3".

Will someone please help me with this

Thanks



Visual Studio Express Editions12  
 
 
MS Johan Stenberg





PostPosted: Visual Basic Express Edition, problems with Configuration manager Top

Could you please post the code where you are running in to this.

The ConfigurationManager is defined in the System.Configuration namespace, and you need to reference System.Configuration in order to access it from your code.

Best regards,
Johan Stenberg



 
 
ahmedilyas





PostPosted: Visual Basic Express Edition, problems with Configuration manager Top

can you post some code as well

I believe you would have to create the SqlConnection string (or oledbConnection) or read the actual connection string from your app settings if stored

just for your reference, a typical SQL Connection string looks like this:

trusted connection:

"Server=.;Database=yourDatabase;Trusted_Connection=true;"

Authentication:

"Server=.;Database=yourDatabase;Trusted_Connection=false;user ID=username;Password=password;"

It would help us if you could post some code especially where the error is being produced