C#短信模板中变量替换问题
可以直接通过 String.Format 方法来做替换,下面链接是官方的示例
var firstName = 'Matt';
var lastName = 'Groves';
var str = String.Format('My name is {0} {1}', firstName, lastName);
https://docs.microsoft.com/zh-cn/dotnet/csharp/tutorials/string-interpolation#intro-to-string-interpolation
赞0
踩0