What is proper RegEx expession for SWIFT codes?
- by abatishchev
I have to filter user input to on my web ASP.NET page:
<asp:TextBox runat="server" ID="recipientBankIDTextBox" MaxLength="11" />
<asp:RegularExpressionValidator runat="server" ValidationExpression="?" ControlToValidate="recipientBankIDTextBox" ErrorMessage="*" />
As far is I know SWIFT code must contain 5 or 6 letters and other symbols up to total length 11 are alphanumeric.
How to implement such rule properly? TIO