I have the following appsettings.json
inside my Asp.NET core console application:-
{
"ConnectionStrings": {
"ConnectionString": "Server=localhost;Database=ServiceDesk;Trusted_Connection=True"
},
"SP": {
"SiteURL": "https://***.sharepoint.com/"
}
}
now i want to access the SiteURL
, i tired the following but it did not work:-
var section = config.GetSection("SP");
var ClientConfig = section.GetChildren();
string siteUrl = ClientConfig.ToString();