[Mono-list] Web.Config connection strings not working - all I get is "Unrecognized attribute 'ConnectionString'. ()"

Pxtl martin.zarate at gmail.com
Sun Nov 16 21:49:00 EST 2008


Web.Config snippets:

<configuration>
   <system.data>
        <DbProviderFactories>
            <add name="MySQL Data Provider"
            invariant="MySql.Data.MySqlClient"
            description=".Net Framework Data Provider for MySQL" 
            type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data,
Version=5.2.3.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" /> 
        </DbProviderFactories>
  </system.data>

also,

<connectionStrings>
    <add 
    	name="COMPANYNAME.QADB" 
    	providerName="MySql.Data.MySqlClient" 
    	ConnectionString="Server=localhost;Database=qa;uid=asp_net;pwd=merc13;" 
    />

and, in my asp.net usercontrol

<asp:SqlDataSource runat="server" id="sdsChips"
	      	  SelectCommand="SELECT * FROM chips" 
	      	  ConnectionString="<%$ ConnectionStrings:COMPANYNAME.QADB%>"
	      	  />

but all I ever get is "Unrecognized attribute 'ConnectionString'. ()", with
a stacktrace that seems mainly to complain about XmlSerializer exceptions.

I'm  using Mono 1.9.1, and Connector/Net 5.2.3, which is supposed to work
well with 1.9.1.

What gives?  I mean, there are workarounds, but a lot of crucial libs expect
the connection string to live in the connectionStrings section.
-- 
View this message in context: http://www.nabble.com/Web.Config-connection-strings-not-working---all-I-get-is-%22Unrecognized-attribute-%27ConnectionString%27.-%28%29%22-tp20533025p20533025.html
Sent from the Mono - General mailing list archive at Nabble.com.



More information about the Mono-list mailing list