Hi Guys, The below code used to interpolate the string and it is configured in the coding itself.
string Name = "Sakthi";
Console.WriteLine($"Name: {Name}");
Output:
Name: Sakthi
My Need is, I want to configure the interpolation expression in the configuration file and need to show the result after interpolation.
Configuration:
Code:
Console.WriteLine(configurationManager.AppSettings["dataToInterpolate"]);
Expected Result:
Name: Sakthi
For this, We can use string.Format() method. But we want to supply the value explicitly. I am trying to do it dynamically like angular js binding. Can anyone help on this.

Amit GuptaPosted Sep 10, 2019, 2:12 AM
Pankajkumar PatelPosted Sep 9, 2019, 12:08 AM
Bidyasagar MishraPosted Sep 8, 2019, 12:10 AM