Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > datagrid regularexpressionvalidator - what went wrong?

Reply
Thread Tools

datagrid regularexpressionvalidator - what went wrong?

 
 
venkat Murthy
Guest
Posts: n/a
 
      04-21-2005
Hi,

I have 10 regularexpression validators in my datagrid.

my datagrid looks like;

first5controls | boundcolumn | next5controls.

Regularexpressionvalidator for first five controls works fine. But, it
throws wierd errors when the error message is caught for next5controls.

Say, error is caught on control6 and control7, the same error is repeated in
all the next5controls.

my control code is like this. and the same is for all 10 controls with
different sort expressions and labels, and text and control to validate.

<asp:TemplateColumn SortExpression="SomeSort1" HeaderText=" This is fifth ">
<ItemTemplate>
<asp:Label id="lblSort" runat="server"
Text='<%#DataBinder.Eval(Container.DataItem, "SortOrder")%>'>
</asp:Label>
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox id="txtExchange" runat="server" Width="30px"
Text='<%#DataBinder.Eval(Container.DataItem, "SortOrder")%>'>
</asp:TextBox>&nbsp;
<asp:RegularExpressionValidator id="Regularexpressionvalidator6"
Width="125px" runat="server" CssClass="hr10" Display="Dynamic"
ErrorMessage="Please use only numbers"
ControlToValidate="txtExchange"
ValidationExpression="[0-9]"></asp:RegularExpressionValidator>
</EditItemTemplate>
</asp:TemplateColumn>

Can someone help me on this?

venkat.Murthy


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
RequiredfiledValidator and regularexpressionvalidator in DataGrid footer Patrick.O.Ige ASP .Net Datagrid Control 4 11-18-2005 08:24 AM
ValidationSummary not displaying error message from datagrid regularExpressionValidator Markus ASP .Net Datagrid Control 0 03-02-2005 05:21 PM
regularexpressionvalidator numeric control Salim Af■ar ASP .Net 2 08-05-2003 01:30 PM
RegularExpressionValidator for money?? Helixpoint ASP .Net 2 06-30-2003 11:41 PM
RegularExpressionValidator - check for empty field Oleg Ogurok ASP .Net 1 06-25-2003 08:32 PM



Advertisments