Strange Error

Posted on 2006-04-13
Last Modified: 2010-07-27
I have a datasource which I use with a gridview, here is the line

<asp:SqlDataSource ID="sub_table_conn" runat="server" ConnectionString="<%$ ConnectionSrings:textConn %>" SelectCommand="SELECT sub_type_id,sub_type FROM tblsubcategories">

No I get this message.  Do I have to register the connection or something,? Thanks in advance Andrew

Here is the error

Parser Error Message: The expression prefix 'ConnectionSrings' was not recognized.  Please correct the prefix or register the prefix in the <expressionBuilders> section of configuration.

Source Error:

Line 12:         <asp:GridView ID="GridView1" runat="server" DataSourceID="sub_table_conn">
Line 13:         </asp:GridView>
Line 14:         <asp:SqlDataSource ID="sub_table_conn" runat="server" SelectCommand="SELECT sub_type_id,sub_type FROM tblsubcategories" ConnectionString="<%$ ConnectionSrings: textConn %>" >
Line 15:         </asp:SqlDataSource>
Line 16:     </div>

Source File: /andy/test_area/default.aspx    Line: 14
Question by:REA_ANDREW
    LVL 10

    Accepted Solution

    'ConnectionSrings' needs to be: 'ConnectionStrings'
    LVL 52

    Assisted Solution

    by:Carl Tawn
    Looks like a simple typo. You have "ConnectionSrigns" rather than "ConnectionStrings", note the "t" in Strings.
    LVL 20

    Author Comment

    A simple "DOH!!!!" KINDA SUMS IT UP..... LOL

    Cheers guys

    LVL 52

    Expert Comment

    by:Carl Tawn
    It happens to us all ;o)

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    In this Article, I will provide a few tips in problem and solution manner. Opening an ASPX page in Visual studio 2003 is very slow. To make it fast, please do follow below steps:   Open the Solution/Project. Right click the ASPX file to b…
    I recently went through the process of creating a Calendar Control of events with the basis of using a database to keep track of the dates that are selectable, one requirement was to have the selected date pop-up in a simple lightbox.  At first this…
    It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
    Internet Business Fax to Email Made Easy - With eFax Corporate (, you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

    759 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    10 Experts available now in Live!

    Get 1:1 Help Now