473,320 Members | 2,145 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

xml tags unrecognised by server??

I am new to xml and I am trying to use xml as web.config file. I will
use asp.net form to get the web.config settings. Below is my
web.config file:

<?xml version="1.0" encoding="UTF-8" ?>

<configuration>

<system.web>

<appSettings>
<add key="Searcharoo_VirtualRoot" value="http://localhost/"
/> <!--website to spider-->
<add key="Searcharoo_RequestTimeout" value="5" /> <!--5
second timeout when downloading-->
<add key="Searcharoo_RecursionLimit" value="200" />
<!--Max pages to index-->
</appSettings>

</system.web>

</configuration>
every time I try to run the asp.net web form, error msg will appear
said that Unrecognized configuration section 'appSettings'. I had do
references on MSDN library and I follow the steps but still get the
same error. I wonder is there anything to do with the asp.net web
form which will get settings from this web.config file? The part of
the file to get settings is as below:

[b:1660e6e52f]// get web.config settings
if (null !=
configurationSettings.appSettings["Searcharoo_RequestTimeout"]) {
prefRequestTimeout =
Convert.ToInt32(configurationSettings.appSettings["Searcharoo_RequestTimeout"]);
}
if (null !=
configurationSettings.appSettings["Searcharoo_VirtualRoot"]) {
startingUri = new Uri
(configurationSettings.appSettings["Searcharoo_VirtualRoot"].ToString()
);
} else {
//startingUri = new Uri ("http://localhost:8080/"); //
occasionally hardcode this for testing...
startingUri = new Uri ("http://" +
Request.ServerVariables["HTTP_HOST"]);
}[/b:1660e6e52f]
I really stuck now and hope that sm 1 will help me out this
problem..Thank you so much.
Posted Via Usenet.com Premium Usenet Newsgroup Services
----------------------------------------------------------
** SPEED ** RETENTION ** COMPLETION ** ANONYMITY **
----------------------------------------------------------
http://www.usenet.com
Nov 12 '05 #1
1 1132


lily82 wrote:
I am new to xml and I am trying to use xml as web.config file. I will
use asp.net form to get the web.config settings. Below is my
web.config file:

<?xml version="1.0" encoding="UTF-8" ?>

<configuration>

<system.web>

<appSettings>
<add key="Searcharoo_VirtualRoot" value="http://localhost/"
/> <!--website to spider-->
<add key="Searcharoo_RequestTimeout" value="5" /> <!--5
second timeout when downloading-->
<add key="Searcharoo_RecursionLimit" value="200" />
<!--Max pages to index-->
</appSettings>

</system.web>

</configuration>
every time I try to run the asp.net web form, error msg will appear
said that Unrecognized configuration section 'appSettings'. I had do
references on MSDN library and I follow the steps but still get the
same error.


The documentation here
<http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconformatofconfigurationfiles.asp>
suggests you need e.g.

<configuration>
<configSections>
<section name="appSettings"
type="System.Configuration.NameValueFileSectionHan dler,
System, Version=1.0.3300.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089"/>

<appSettings>
<add key="dsn" value="localhost;uid=MyUserName;pwd=;"/>
<add key="msmqserver" value="server\myqueue"/>
</appSettings>
</configuration>

that is one "declaration" of the section named "appSettings" in
configSections.

If that doesn't help then perhaps someone in an ASP.NET group knows more.
--

Martin Honnen
http://JavaScript.FAQTs.com/
Nov 12 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Steve | last post by:
My access 2000 project was written on a win 98 machine and has a macro with a condition DateValue(FileDateTime("c:\database\full22.txt"))<Date() This was written in expression builder. On...
11
by: MAB71 | last post by:
My Clients Access 2000 database was working fine with my VB application and Access 2003 until today when he got the message 'Unrecognised Database Format' from both ( app and access 2003 ). He...
2
by: ZMan | last post by:
I'm trying to format some data out as an RSS feed. I already have a perfectly good ASPX page that does the same thing with an <asp:repeater> so I figured I'd take the page change the html tags to...
0
by: SteveR | last post by:
I'm trying to call my web service from a C++ 6.0 application. It works fine on the web server PC but from anyother PC I get the error message 'request format is unrecognised'. I build the request...
0
by: Roger Greenwood | last post by:
I recently needed to recover an MS Access database file from Norton Ghost 10 but I am unable to open the file in Access or any other application. Acess throughs up an "Unrecognised database format"...
2
by: gregmcmullinjr | last post by:
I am wondering if there is a way to use a DTD or Schema to instruct an XML parser to ignore tags that are not defined. That is, if my list of acceptable tags is <bodyand <content>, then in the...
3
by: MikeB | last post by:
Hello, I have a content page that is from a Master page which has 2 content panes. How do I add my forms to the content page? Each pane needs a form but you can not have multiple form tags nor...
1
by: piercy | last post by:
Hi, ive put to gether a function which sends some information to a website and also returns a value depending on the responce from that page. It works excellent in a new project and does exactly...
1
by: dhanu sahu | last post by:
I am store my database and Tables in App_Data.I want to retrive data from that and want to see in Label Control . But I m getting Error As "Unrecognised Escape Sequence" string conn = new...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.