I want to replace the value of two "string" members from their record in Object with the string I want.
I'm trying to use the .Contains() and replace() function on object
This is the object:
EmailParam param = new EmailParam();
And the EmailParam:
public class EmailParam {
  public string UserName {get; set;}
  public string Code {get; set;}
  public string Param1 {get; set;}
  public string Param2 {get; set;}
}
And this is the example:
string body = "My name is @UserName and my code is @Code";
param.UserName = "Tony";
param.Code = "A01";
What I want for result will be like My name is Tony and my code is A01
It is come from find body @UserName, and then replace from value Username Tony
 
     
    