string.Format has following method signature
string.Format(format, params, .., .. , ..);
I want to pass custom format each time like
You can validate with try catch, if format throw exceptin you log information and stop treatment.
try { string.Format(custFormat, params, .., .. , ..); } catch(FormatException ex) { throw ex; } string message = ProcessMessage(custFormat, name);