【发布时间】:2017-08-23 01:27:27
【问题描述】:
考虑下面的代码:
<asp:RegularExpressionValidator
ID="MyTestId"
ValidationGroup="MyTestGroup"
ErrorMessage="You are a silly user. You entered the wrong format for this problem. Please try again. Using this format! ELRLDKX##Z"
ValidationExpression="some unrelated regex"
runat="server"
ControlToValidate="MyTestTextbox">
</asp:RegularExpressionValidator>
有没有办法在 ErrorMessage 字符串中插入某种转义字符以确保 请重试。使用这种格式! ELRLDKX##Z 在另一行?我试过了,\n没有运气。
【问题讨论】:
标签: asp.net .net webforms servercontrols