Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Case Sensitive of elements in web.config and app.config files

Posted on 2014-02-14
3
Medium Priority
?
2,577 Views
Last Modified: 2014-02-21
Are elements of a web.config and app.config case sensitive?

If so, are they just case sensitive in a sense where the open tag and closing tag must match - case wise? They don't need to be upper or lower but just match in case sensitivity sense.


<element1>
</element1>
0
Comment
Question by:metro156
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 21

Expert Comment

by:Craig Wagner
ID: 39859974
The general answer to your question is that XML is case sensitive.

For example, the <connectionStrings> element must contain <add>, <remove>, or <clear> elements. If you put in an <Add> element the application will throw an exception.

Finally, an opening tag of <element> will not match a closing tag of <ELEMENT>.
0
 

Author Comment

by:metro156
ID: 39860038
So are you saying in certain elements like <add>, <remove>, <clear> they have to be lower case no matter what?

However, elements outside of those elements must be matching in case. It doesn't matter if they are both lower or both upper as long as they match opening and closing tags.
0
 
LVL 21

Accepted Solution

by:
Craig Wagner earned 1500 total points
ID: 39860355
So are you saying in certain elements like <add>, <remove>, <clear> they have to be lower case no matter what?

I thought it was pretty clear that's what I said, but let me repeat, <add> good, <Add>, <aDd>, <adD>, <ADD> bad.

XML is case sensitive. web.config is XML. End of story.
0

Featured Post

Containers & Docker to Create a Powerful Team

Containers are an incredibly powerful technology that can provide you and/or your engineering team with huge productivity gains. Using containers, you can deploy, back up, replicate, and move apps and their dependencies quickly and easily.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For most people, the WrapPanel seems like a magic when they switch from WinForms to WPF. Most of us will think that the code that is used to write a control like that would be difficult. However, most of the work is done by the WPF engine, and the W…
Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…

715 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