I am using Entity Framework. In app.config there is stored connection string that EF generates for my database.
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<configSections>
</configSections>
<connectionStrings>
<add name="votemeEntities" connectionString="metadata=res://*/VoteModel.csdl|res://*/VoteModel.ssdl|res://*/VoteModel.msl;provider=MySql.Data.MySqlClient;provider connection string="server=localhost;User Id=root;database=voteme""
providerName="System.Data.EntityClient" />
<add name="VoteMe.Properties.Settings.votemeConnectionString"
connectionString="server=localhost;User Id=root;database=voteme"
providerName="MySql.Data.MySqlClient" />
</connectionStrings>
</configuration>
I need to set Charset in this connection string. How do I do it so my EF use this connection string without any problems?
Thanks
You can add the property at the end of the EF connection string, just before the
".Just make sure that the value is properly XML escaped (if needed), otherwise you will break the config file.