Error: Error parsing entityname Web configuration

Source: Internet
Author: User

The environment in which this error occurs: ASP. NET or XML
Case: An otherwise healthy C # page, because the SQL password has changed since the " error parsing EntityName "error, verifying that the password for SQL connectionstring for Web. config is changed. In the baffled solution, found VisualStudio (2008) Open web.config will put some two characters of the SQL password &N Red flag "undefined entity" N "", suddenly understood, because web.config is the XML content, In XML, "&" is used for defined character entities, i.e. sql ConnectionString.
FIX: Change SQL password to non-"& character" form
Attached: XML character entity

XML character Entity

As mentioned above, most of the character entities and escapes that are commonly used when writing XAML markup are defined by XML. This topic does not provide a complete list of similar entities, and more deterministic references to these entities can be found in external documents such as XML specifications. However, for the sake of convenience, this topic lists some specific XML character entities that are often used for XAML markup.

Character

Entity

Description

& ("and" character)

&

Must be used both for the property value and for the content of the element.

> (greater than sign character)

<

Must be used for property values, but as long as there is no < in front, you can accept > as the content of the element.

< (less than sign character)

&lt;

Must be used for attribute values, but as long as there is no following, you can accept < as the content of the element.

"(double quote character)

&quot;

Must be used for the property value, but acceptable as the content of the element. Note that the property value itself can be caused by ' or ', the property value shell is defined by the first quotation marks, and the other quotation mark can then be used as the text in the value.

' (single quote character)

&apos;

Must be used for the property value, but acceptable as the content of the element. Note that the property value itself can be caused by ' or ', the property value shell is defined by the first quotation marks, and the other quotation mark can then be used as the text in the value.

(digital word mappings shot)

&#[integer]; or & #x [hex];

XAML supports mapping numeric characters to an active encoding.

(non-breaking spaces)

& #160; (with UTF-8 encoding)

For flow document elements or elements that use text, such as a TextBox, nonbreaking spaces are not normalized outside the markup, as are xml:space= "default" (see Whitespace processing in XAML for details).

XML Comment Format

XAML uses the XML comment format: Comments begin with the <!--,-->, end, the note must not appear-sequence.

Source: http://blog.sina.com.cn/s/blog_6452c6b40100nbw2.html

Error: Error parsing entityname Web configuration

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.