Configuration :: A Section Using 'configSource' May Contain No Other Attributes Or Elements?

Oct 14, 2010

I have web app that compiles, but when I try to run it, it gives the following error:

"A section using 'configSource' may contain no other attributes or elements", I have made some research on this and still couldn't get anything.

Note: This is happening in the Web.Config file of the web app like this:

<system.web>
<pages
configSource="ConfigPages.config"
controlRenderingCompatibilityVersion="3.5"
clientIDMode="AutoID">
</pages>

View 1 Replies


Similar Messages:

Use MailSettingssmtp With Both The ConfigSource And From Attributes?

Jan 15, 2010

I am trying to clean up our web.config file such that per-deployment specific stuff is not kept in the main config. I have managed with the connections strings and some of the mailSettings, but I need the from attribute as well as the configSource, but this doesn't seem to be allowed.

Currently I have this:

web.config:

<system.net>
<mailSettings >
<smtp configSource="email.config" from="me@blahblah.com" />
</mailSettings>
<defaultProxy>
<proxy bypassonlocal="True" usesystemdefault="False" />
</defaultProxy>
</system.net>
email.config
<network host="myhost" password="" userName="" />

Ideally I would have the set the configSource on either mailSettings or system.net, but this isn't supported.

Is there a better way to do this?

View 2 Replies

Format Of A ConfigSource File Must Be An Element Containing The Name Of The Section?

Mar 28, 2011

I 'm trying to connect to the database in file settings.web but displayed error.
What's wrong?

web.config:
[Code]....

An error occurred during the processing of a configuration file required to
service this request. Please review the specific error details below and modify
your configuration file appropriately. Parser Error Message: The
format of a configSource file must be an element containing the name of the
section.

View 1 Replies

Configuration :: The Configuration Section ConnectionStrings Cannot Be Read Because It Is Missing A Section Declaration

Mar 17, 2010

Detailed Error Information
Module
IIS Web Core
Notification
Unknown
Handler
Not yet determined
Error Code
0x80070032

Config Error The configuration section 'connectionStrings' cannot be read because it is missing a section declaration Config File \?C:inetpubvhostscno-o.comhttpdocsweb.config

View 9 Replies

Configuration :: Appsettings ConfigSource?

Jun 24, 2010

I have splitted the appSettings from web.config file and put it under 'App_ConfigappSettings.config' which is mapped using configSource attribute.web.config :

[Code]....

It is working fine in my local machine. But giving problem while hosting the application to web server.i.e, Can not find appsettings

View 3 Replies

IIS Configuration :: Adding Add Section In HttpHandler Section In Web Config Results In Blank Page?

Jul 12, 2013

with this code website works perfect

<configuration>
<system.web>
<httpHandlers>
</httpHandlers>
</system.web>
</configuration>

but when I add

<add path="ThumbHandler.ashx" verb="*" type="Delshad.WebControls.ThumbHandler,Delshad.ThumbPic"/>

or

<add verb="GET" path="CaptchaImage.axd"
type="MSCaptcha.CaptchaImageHandler, MSCaptcha" />

in httphandlers section when I go in my site it is only a blank page!

before In other two host there wasent problem but this is a new host and I face with this problem.also in local there isn't any problem.

View 1 Replies

Configuration :: Error "The Configuration Section "connectionStrings" Cannot Be Read Because It Is Missing A Section" When Loading Page

Mar 5, 2010

I have this error: The configuration section 'connectionStrings' cannot be read because it is missing a section declaration on my site when loading this page [URL]. The rest of the site works [URL] Setup:The server is a hosting company - Mocha Hosting. [URL] contains a phpbb forum. This has been installed via the hosting company's web tool (Plesk). There is a root web.config, but there isn't in the /forum/ folder. The forum folder has been set by the phpbb installation wizard to be a virtual directory and application - and it appears to not have asp.net configured on it. The forum worked BEFORE uploading the root web.config file, and again if i temporarily remove the root web.config.

View 5 Replies

The Configuration Section "system.web.extensions" Cannot Be Read Because It Is Missing A Section

Apr 14, 2010

My system: I have installed Windows 7, VS2010 and .NET40 and ASPAJAXExtSetup.msi I'm getting the error below.

Error Summary. HTTP Error 500.19 - Internal Server Error The requested page cannot be accessed because the related configuration data for the page is invalid.

View 13 Replies

Configuration :: Configuration Error / Unrecognized Configuration Section System.serviceModel?

Mar 10, 2010

I am getting this error on a website. does that mean the server is not competible with asp.net 3.5

Configuration Error
Description:An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Unrecognized configuration section system.serviceModel.

Source Error: [Code]....

Line 236: </assemblyBinding>Line 237: </runtime>Line 238: <system.serviceModel>Line 239: <serviceHostingEnvironment aspNetCompatibilityEnabled="true" />Line 240: </system.serviceModel>

Source File: D:Inetpubvhostsmuratmalli.comhttpdocsweb.config Line:
238

View 2 Replies

Configuration :: Error Occurred Creating The Configuration Section Handler?

Jun 4, 2010

Excuse me this common error. I´ve found a lot of info in Google but I´ve not found my error. I´m trying to read some data from a custom section in web.config and I don´t know which is my error?

[Code].....

View 1 Replies

JQuery :: JQuery And Custom Attributes/ Find All Input Elements That Will Require Validation?

Jul 14, 2010

to directly get all elements in a form who contains a non html attribute ?

<input .... customAttribute="validateMe">

So I could find all input elements that will require validation.And use this in a loop to add validation to the input's found :

$('input').attr("customAttribute").val() == "validateMe"

I could also write every validation for each object separately, I have only a few elements who uses a required validation but it would be nice that I could do this in one shot instead of repeating the $("input").rules("add .....

View 5 Replies

Checking A HTML Elements Class Attributes Value Contains "String"?

Nov 10, 2010

I have two user controls that need to add a class atribute to the body tag of my page, however they currently over write one another if I just use

Body.Attributes.Add("class","value")

So I need to check if the class attribute exsists and if it already contains the value Im going to add.

If Not Body.Attributes("class").Contains("value") Then
Body.Attributes.add("class", Body.Attributes("class") + " " + "value")
End If

View 1 Replies

Give Style Attributes To Sub-elements Inside A <style> Tag?

Apr 9, 2010

My <style> for thumbnails currently looks like this:

<style type="text/css">
img.TN {
width: 100%;
margin-bottom: 5.294%;
cursor: pointer; }
</style>

This is annoying, because I have to apply this style to every single thumbnail image individually, when there could be any number of them on the screen at any given time. All of the thumbnails are inside a single <div> that groups them together, and I'd like to apply a single style to the <div> that will push the attributes I need down to all of the the <img> elements nested inside, regardless how many thumbnails there are.

I'm using ASP.NET 2.0, and CSS 2.0

View 2 Replies

C# - App.Config Custom Configuration Section

Dec 14, 2010

I've created a custom config section for my application. For some reason Visual Studio 2010 isn't picking up and of my custom properties. I'm getting warnings similar to this for all the "add" keys: Could not find schema information for the element 'urlFilterSection'

CONFIG FILE:
<configSections>
<section name="urlFilterSection" type="BotFinderApp.Models.UrlFilterSection, BotFinder" />
</configSections>
<urlFilterSection>
<urlFilterCollection>
<add url="urlhere.com.au" numberOfIpsToExtract="10" />
<add url="urlhere.com.au" numberOfIpsToExtract="10" />
<add url="urlhere.com.au" numberOfIpsToExtract="10" />
<add url="urlhere.com.au" numberOfIpsToExtract="10" />
<add url="urlhere.com.au" numberOfIpsToExtract="10" />
<add url="urlhere.com.au" numberOfIpsToExtract="10" />
<add url="urlhere.com.au" numberOfIpsToExtract="10" />
<add url="urlhere.com.au" numberOfIpsToExtract="10" />
<add url="urlhere.com.au" numberOfIpsToExtract="10" />
</urlFilterCollection>
</urlFilterSection>
UrlFilterSection:
namespace BotFinderApp.Models
{
public class UrlFilterSection : ConfigurationSection
{
public UrlFilterSection()
{
}
[ConfigurationProperty("urlFilterCollection", IsDefaultCollection = false)]
[ConfigurationCollection(typeof(UrlFilterCollection), AddItemName = "add", ClearItemsName = "clear", RemoveItemName = "remove")]
public UrlFilterCollection Urls
{
get
{
var urlsCollection = (UrlFilterCollection)base["urlFilterCollection"];
return urlsCollection;
}
}
}
}
UrlFilterCollection
namespace BotFinderApp.Models
{
public class UrlFilterCollection : ConfigurationElementCollection
{
public UrlFilterCollection()
{
}
protected override ConfigurationElement CreateNewElement()
{
return new UrlFilter();
}
protected override object GetElementKey(ConfigurationElement element)
{
return ((UrlFilter)element).Url;
}
}
}
UrlFilter
namespace BotFinderApp.Models
{
public class UrlFilter : ConfigurationElement
{
public UrlFilter()
{
}
[ConfigurationProperty("url", DefaultValue = "", IsRequired = true)]
public string Url
{
get { return (string)this["url"]; }
set { this["url"] = value; }
}
[ConfigurationProperty("numberOfIpsToExtract", DefaultValue = "0", IsRequired = true)]
public int NumberOfIpsToExtract
{
get { return (int)this["numberOfIpsToExtract"]; }
set { this["numberOfIpsToExtract"] = value; }
}
}
}

View 2 Replies

Configuration Of Forms Authentication Section ?

Nov 3, 2010

I have an ASP.NET MVC application running on IIS. In my web.config I defined following section responsible for forms authentication:

<authentication mode="Forms">
<forms
loginUrl="~/Account/LogOn" [code]....

Why do I get a different address from the one defined in web.config?

UPDATE: The "/VNK/site/" prefix is not a problem here. The problem is that LoginUrl property of FormsAuthentication class does not reflect the value from web.config. It means that if I change in web.config loginUrl from "~/Account/LogOn" for example to "~/foobar", FormsAuthentication.LoginUrl still has value of "/VNK/site/Account/Login". Why ?

View 3 Replies

C# - Unrecognized Configuration Section Rewriter?

Jun 3, 2010

I'm trying to implement Approach 3 from this Url Rewriting article.I've added all the required configuration (in web.config for the UrlRewriter module) but when i try to add this in web.config:

<configuration>
<configSections>
<sectionGroup>

[code]...

View 1 Replies

Configuration :: Error - "Configuration Section Encryption Is Not Supported"

Nov 3, 2010

I have been using the aspnet_regiis to encrypt my web configs in .net 2.0. I have recently moved my application to .net 4 and the encryption runs without any issues but when I try to view the site, I get a 500.19 error "Configuration section encryption is not supported".

I have verified that my web config contains "<validation validateIntegratedModeConfiguration="false" />"

View 1 Replies

Configuration :: How To Change The Subfolder Attributes

Mar 20, 2010

Using VS 2010, RC, VB, how do I change the subfolder attributes. When I publish and choose to delete all the files and folders, I have to recreate the security levels for them manually. I assume that I can have Web Config do that for me.

View 1 Replies

Configuration :: Registering A Custom Section In Web.config?

Feb 12, 2010

I'm getting an ConfigurationErrorsException when trying to load a custom section from my web.config.

I'm trying to register a custom section in web.config to load it later using a "Section Class".
Suppose my section is orderService, and I register it in web.config as shown:
<configuration>
<configSections>
<sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
</sectionGroup>
<section name="orderService" type="orderService"/>
</configSections>
<orderService available="true" pollTimeout="00:01:00" location="abc">
</orderService>
<appSettings></appSettings>
<connectionStrings/>

Then I try to load it with:

Configuration config = WebConfigurationManager.OpenWebConfiguration(Request.ApplicationPath);
OrderService custSection = OrderService)config.GetSection("orderService"); <== The exception is thrown here (OrderService is a class that inherits from the class ConfigurationSection, and that defines a property for each orderService property, in this case: available, pollTimeout and location)

The exception says: An error occurred creating the configuration section handler for orderService: Could not load type 'orderService'. (my web.config path line 23) Does anybody know what am I doing wrong here? (I got it from the book APress: Pro ASP.NET 3.5 in C#)

View 2 Replies

Configuration :: Encrypting A Custom Section Programatically

Aug 11, 2010

I have a custom section in a web application that I am having trouble encrypting. I have written an external .NET program that will encrypt both .NET 1.1 & .NET 2.0 web/app configs.Up until this point in time, I have never had to encrypt any custom sections for either type of application. Anyway, the way I set it up for my web application is I wrote a class library that I import into the web application which allows me to set up and read from the custom section in the web.config. That all works fine... I added the custom section, and the web pages are able to read the values fine.

View 1 Replies

Configuration :: Web Confg Compilation Section Error

Mar 21, 2011

Why would I be getting this error message ? I have not touched this part of my application ?Error 5 Section or group name 'compilation' is already defined. Updates to this may only occur at the configuration level where it is defined. C:Documents and Settingsk4gp5My DocumentsVisual Studio 2010WebSitesweb.config 6

View 2 Replies

How To Read System.webserver Configuration Section

Sep 6, 2010

Is there any way to read configuration section group of IIS7 by using WebConfigurationManager o anything?

I tried to read the authorization section but WebConfigurationManager.GetSection() returns an 'IgnoredSection' instance.

This is what my code looks like...

authSection = WebConfigurationManager.GetSection("system.webServer/security/authorization", HttpContext.Current.Request.Path)

View 1 Replies

C# - StringValidator Always Fail For Custom Configuration Section?

Aug 27, 2010

I have created a custom configuration section in a c# class library by inheriting from ConfigurationSection. I reference the class library in my web application (also c#, ASP.NET), fill in the appropriate attributes and everything works great. The problem starts when I start adding validators.

For example, this property:

[ConfigurationProperty("appCode", IsRequired = true)]
public string ApplicationCode
{
get
{
return (string)base["appCode"];
}
set
{
base["appCode"] = value;
}
}

As is it works fine, but as soon as I add this:

[StringValidator(MinLength=1)]

It bombs with the following error:

The value for the property 'appCode' is not valid. The error is: The string must be at least 1 characters long.

I get this error even though a valid appCode value is in my web.config file. If I remove the validator it works perfectly.

View 2 Replies

How To Modify Configuration Section Programmatically In Medium Trust

Jan 30, 2011

I have a custom ConfigurationSection in my application:

public class SettingsSection : ConfigurationSection
{
[ConfigurationProperty("Setting")]
public MyElement Setting
get
[code]...

View 1 Replies

Error 500.19 - Configuration Section 'system.web.extensions' Cannot Be Read?

Jun 8, 2010

I am running a 4.0 environment on my development machine (VS 2010 + .NET4) and my server (2008 SERVER + just installed .NET 40). On my dev environment, I don't get any errors, but with the same web config on the server, I get: Error 500.19 - The configuration section 'system.web.extensions' cannot be read because it is missing a section declaration

[code]...

View 4 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved