S
sandy.82in
Hi
I'm new to C# , I'm using VS2005 and .NET2.0 .Here is my
issue i just developed a simple application with app.config , and a
simple class library and following is my app.configfile
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<appSettings>
<add key="Setting1" value="Very" />
<add key="Setting2" value="Easy" />
</appSettings>
</configuration>
and class library to call my appsettings
public class Class1
{
public string ReturnMsg()
{
string value = "";
foreach (string key in
System.Configuration.ConfigurationManager.AppSettings)
{
value +=
System.Configuration.ConfigurationManager.AppSettings[key];
}
return value;
}
}
Now my issue i'm getting value as null , why is that am i missing
anything i'm trying this from past 2 days please cananyone help
me .Are there any setting changes that i have to make . I tried
without foreach statement even then no luck. can anyone please tell me
where i'm going wrong .
thanks in advance
I'm new to C# , I'm using VS2005 and .NET2.0 .Here is my
issue i just developed a simple application with app.config , and a
simple class library and following is my app.configfile
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<appSettings>
<add key="Setting1" value="Very" />
<add key="Setting2" value="Easy" />
</appSettings>
</configuration>
and class library to call my appsettings
public class Class1
{
public string ReturnMsg()
{
string value = "";
foreach (string key in
System.Configuration.ConfigurationManager.AppSettings)
{
value +=
System.Configuration.ConfigurationManager.AppSettings[key];
}
return value;
}
}
Now my issue i'm getting value as null , why is that am i missing
anything i'm trying this from past 2 days please cananyone help
me .Are there any setting changes that i have to make . I tried
without foreach statement even then no luck. can anyone please tell me
where i'm going wrong .
thanks in advance