Hi All
I'm a long time VB developer learning C#. I'm loving it, but I have a question.
I have a class that reads my config settings out of my web.config file and passes them to several parts of my program.
In the VB world this class was static so I didn't not have ti instantiate it. Can I continue this into the C# world or is there a better way?
Code below.
I'm a long time VB developer learning C#. I'm loving it, but I have a question.
I have a class that reads my config settings out of my web.config file and passes them to several parts of my program.
In the VB world this class was static so I didn't not have ti instantiate it. Can I continue this into the C# world or is there a better way?
Code below.
Code:
public static class AppConfiguration
{
private readonly string m_dbConnectionString;
public static string DbConnectionString
{
get { return m_dbConnectionString; }
}
}