Can anybody tell me how we write validation formula for "single line of text" fields in SharePoint list that it accepts characters only.
3 Answers
3
votes
I think without SP Designer is this not possible. There are following functions available: ISBLANK ISERR ISERROR ISLOGICAL ISNA ISNONTEXT ISNULL ISNUMBER ISTEXT See this reference: http://office.microsoft.com/en-us/sharepoint-foundation-help/is-functions-HA100405908.aspx
0
votes
-1
votes
Try this code
<%@ language="C#" %>
<form id="form1" runat="server">
<asp:TextBox ID="txtName" runat="server"/>
<asp:Button ID="btnSubmit" runat="server" Text="Submit" />
<asp:RegularExpressionValidator ID="regexpName" runat="server"
ErrorMessage="This expression does not validate."
ControlToValidate="txtName"
ValidationExpression="^[a-zA-Z'.\s]{1,40}$" />
</form>