469,917 Members | 1,610 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,917 developers. It's quick & easy.

Error messages with Validators

I have a problem where I have some text boxes in my datagrid.

The problem is the message gets displayed and moves the cells to the right.

Is there a way to tell the messages to go to a specific asp:label? If I
could put the label at the bottom of the page (or top) and tell the
Validator to put it there that would solve the problem.

I suppose I could use the CustomValidator for my ranges, but I was wondering
if there was a different way to handle this.

Thanks,

Tom
Nov 19 '05 #1
5 936
Why dont you use Validation Summary control to display all the error
messages. This way you ensure that messages are displayed in the summary
control., which you can position where ever you want, possibly at the top of
the page
--
Kumar Reddi
http://kumarreddi.blogspot.com

"tshad" <ts**********@ftsolutions.com> wrote in message
news:u7**************@tk2msftngp13.phx.gbl...
I have a problem where I have some text boxes in my datagrid.

The problem is the message gets displayed and moves the cells to the right.
Is there a way to tell the messages to go to a specific asp:label? If I
could put the label at the bottom of the page (or top) and tell the
Validator to put it there that would solve the problem.

I suppose I could use the CustomValidator for my ranges, but I was wondering if there was a different way to handle this.

Thanks,

Tom

Nov 19 '05 #2
"Kumar Reddi" <ku********@REMOVETHIS.gmail.com> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
Why dont you use Validation Summary control to display all the error
messages. This way you ensure that messages are displayed in the summary
control., which you can position where ever you want, possibly at the top of the page
I'll check that out. I didn't know about that or how it works. Will check
it out tomorrow.

thanks,

Tom --
Kumar Reddi
http://kumarreddi.blogspot.com

"tshad" <ts**********@ftsolutions.com> wrote in message
news:u7**************@tk2msftngp13.phx.gbl...
I have a problem where I have some text boxes in my datagrid.

The problem is the message gets displayed and moves the cells to the

right.

Is there a way to tell the messages to go to a specific asp:label? If I
could put the label at the bottom of the page (or top) and tell the
Validator to put it there that would solve the problem.

I suppose I could use the CustomValidator for my ranges, but I was

wondering
if there was a different way to handle this.

Thanks,

Tom


Nov 19 '05 #3
Tom try seeing this tutorial at:-
http://authors.aspalliance.com/aspxt...idationsummary
control.aspx
Hope it helps
Patrick

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 19 '05 #4
tshad wrote:
I have a problem where I have some text boxes in my datagrid.

The problem is the message gets displayed and moves the cells to the right.

Is there a way to tell the messages to go to a specific asp:label? If I
could put the label at the bottom of the page (or top) and tell the
Validator to put it there that would solve the problem.

I suppose I could use the CustomValidator for my ranges, but I was wondering
if there was a different way to handle this.

Thanks,

Tom


The validator doesn't need to be right next to the textbox it is
validating, you can put it anywhere on the page. The link between
textbox and validator is via ControlToValidate.
(and, as others said, look into ValidationSummary)

--
Hans Kesting
Nov 19 '05 #5
"Hans Kesting" <ne***********@spamgourmet.com> wrote in message
news:ut*************@TK2MSFTNGP15.phx.gbl...
tshad wrote:
I have a problem where I have some text boxes in my datagrid.

The problem is the message gets displayed and moves the cells to the
right.

Is there a way to tell the messages to go to a specific asp:label? If I
could put the label at the bottom of the page (or top) and tell the
Validator to put it there that would solve the problem.

I suppose I could use the CustomValidator for my ranges, but I was
wondering if there was a different way to handle this.

Thanks,

Tom
The validator doesn't need to be right next to the textbox it is
validating, you can put it anywhere on the page. The link between
textbox and validator is via ControlToValidate.
(and, as others said, look into ValidationSummary)


You're right. I hadn't thought of that. I am going to look at both
options.

Thanks,

Tom
--
Hans Kesting

Nov 19 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

6 posts views Thread by gh0st54 | last post: by
3 posts views Thread by tshad | last post: by
2 posts views Thread by David Thielen | last post: by
2 posts views Thread by Mike Hofer | last post: by
7 posts views Thread by saurabh | last post: by
3 posts views Thread by Eric Layman | last post: by
1 post views Thread by Waqarahmed | last post: by
reply views Thread by Salome Sato | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.