473,394 Members | 1,737 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,394 software developers and data experts.

Application Configuration File?

What Application Configuration File is? And
when/where/how to use it? Any documents on that? MSDN has
somrthings scatter everywhere - hard to follow.

thanks,

Jul 19 '05 #1
2 3422
Kathy,
An Application Configuration File is an XML file that .NET uses to configure
your application.

For ASP.NET applications the file is called web.config. At run time it is
still called web.config.

For Windows applications, the file is called app.config. At run time the
app.config is called myexe.exe.config and need to be in the same directory
as the exe itself.

Class libraries (.dll files) do not have an Application Configuration File,
they need to rely on either the web.config or the app.config.

When you use 'Project - Add New Item - Application Configuration File' in
VS.NET to add one to your project it will be named either app.config or
web.config per above. At runtime it will be moved to the appropriate folder
and used.

There is also a machine.config file, that .NET uses to configure your
application. This file is merged with the app.config with the app.config
getting precedence. In other words you can use the machine.config to have
global settings that are shared across apps, then use the app.config to
override some of these settings.

The two primary sections of the app.config are configSections and
appSettings. appSettings is a predefined section that allows you to define
name/value pairs. You use
System.Configuration.ConfigurationSettings.AppSett ings to read values from
the appSettings section.

configSections allows you to define your own sections. You use
System.Configuration.ConfigurationSettings.GetConf ig to retrieve these
values.

See the following for create new sections via the configSections section.

http://msdn.microsoft.com/library/de...onhandlers.asp

and:
http://msdn.microsoft.com/library/de...ionsschema.asp

Also read about the System.Configuration.ConfigurationSettings class and
other classes in the System.Configuration namespace.

And yes, the documentation is scattered & hard to follow...

Hope this helps
Jay

"kathy" <ka***@nospam.com> wrote in message
news:00****************************@phx.gbl...
What Application Configuration File is? And
when/where/how to use it? Any documents on that? MSDN has
somrthings scatter everywhere - hard to follow.

thanks,

Jul 19 '05 #2
The intent was not to offend you which you seem to have been so my
apologies.

Good luck in your search and hope Jay's answer following mine is more
helpful.

Peace.

"kathy" <ka***@nospam.com> wrote in message
news:03****************************@phx.gbl...
"specific technical questions" means what? My question IS
a specific technical questions.

your answer is useless.

Jul 19 '05 #3

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

Similar topics

2
by: Terence Shek | last post by:
Is there a way to set the application binding policy so that it always binds to the latest version of an assembly? I'm hoping there is a way to avoid updating the application's binding...
6
by: Javier Cortés Cortés | last post by:
i am getting this error when i am trying to access any file(with the ext. aspx) from my remote server. the error is : Server Error in '/' Application....
3
by: Damian | last post by:
Hi everyone I'm having an issue with one of our applications. I'm getting the following error when attempting to log in to the site: Server Error in 'xxxxxxxxxxxxxxxx' Application....
4
by: tommy | last post by:
hello everbody, i write a little asp-application with forms-authentication. i copy my aspx-files with web.config to my webspace and i get the error above... i tried to set the...
9
by: Wayne Wengert | last post by:
I built an ASP application and it runs fine on my local IIS. I am trying to move the application to my web service (ISP) out on the internet. I've read several of the help articles but they all...
0
by: George Durzi | last post by:
I'm trying to extend the ExceptionManager Application Block and build a custom publisher that writes my exceptions to the database. That's easy part. The difficulty I am having is in configuring my...
3
by: Sean | last post by:
HI There, I am having trouble deploying my .aspx pages to a remote server, I have made changes to the config file and it still returns an error. I have also contacted the server administrator to...
12
by: Kevin Farless | last post by:
Hi all, I'm having trouble viewing any .aspx pages on my hosting company's server. The server is a new box running Windows Server 2003 default installation. I'm the first client to try using...
5
by: rdcpro | last post by:
In reading MSDN docs on creating custom Configuration sections, I found this page: ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.