472,145 Members | 1,428 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,145 software developers and data experts.

edit in place for data grid columds

can anyone send me to some good examples of edit in place for data frid
columns

i see dot net let me assign a control in the IDE

any good sources of reading on editing columns with controls and setting
styles

thanks

steve
Jun 9 '07 #1
6 2311
hi i'm new to .net field, i'm developing one application using ASP.NET
and C#.NET in that i get one problem that is how to validate user
entered date and time formate, for this problem wheather i have to use
RegularExpressionValidator or any other Code, Give the response soon
i'm waiting for reply

Jun 11 '07 #2
I'm sure there are good reasons for doing this client side, but I've never
found one.

Data entry validation always needs to be done server-side when the user
submits the form: so why not just settle for that and do the validation
server side? You're doing a postback anyway, so there's no extra time taken
worth talking about.

I know that some people like to do validation as the data is entered, but I
don't really like that - as a user or as a designer: but I know opinions
vary. However, good practice determines that all the data is checked
server-side on submit anyway, so checking client-side is just doing the job
twice IMHO.

[In case anyone asks, the reason that data entry has to be checked server
side anyway is because you cannot be certain that the data was submitted
from the form exactly as you wrote it. People can turn off scripting; they
can save the page and modify it. All sorts of nefarious stuff can go on
between the server and client]

I'm tempted to sign off as Paranoid Peter, but I'll just make do with my
usual

HTH

Cheers
Peter

<ne********@gmail.comwrote in message
news:11**********************@n15g2000prd.googlegr oups.com...
hi i'm new to .net field, i'm developing one application using ASP.NET
and C#.NET in that i get one problem that is how to validate user
entered date and time formate, for this problem wheather i have to use
RegularExpressionValidator or any other Code, Give the response soon
i'm waiting for reply

Jun 11 '07 #3
"Peter Bradley" <pb******@uwic.ac.ukwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
I'm sure there are good reasons for doing this client side, but I've never
found one.
To minimise the number of round trips to the server and back...
Data entry validation always needs to be done server-side when the user
submits the form: so why not just settle for that and do the validation
server side? You're doing a postback anyway, so there's no extra time
taken worth talking about.
Not true at all...

E.g. if you are writing a subscription site where users need to register,
and one of the criteria for registration is that registrants needs to be at
least 18 years old, then a simple client-side validation is perfectly fine -
there's no need for a round trip just to do that...

Or for checking that a date value is greater or less than another date value
e.g. today's date...

Or, even more importantly, to validate that mandatory fields actually do
contain a value...
--
http://www.markrae.net

Jun 11 '07 #4


"Mark Rae" <ma**@markNOSPAMrae.netwrote in message
news:Ov**************@TK2MSFTNGP03.phx.gbl...
"Peter Bradley" <pb******@uwic.ac.ukwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
>I'm sure there are good reasons for doing this client side, but I've
never found one.

To minimise the number of round trips to the server and back...
>Data entry validation always needs to be done server-side when the user
submits the form: so why not just settle for that and do the validation
server side? You're doing a postback anyway, so there's no extra time
taken worth talking about.

Not true at all...

E.g. if you are writing a subscription site where users need to register,
and one of the criteria for registration is that registrants needs to be
at least 18 years old, then a simple client-side validation is perfectly
fine - there's no need for a round trip just to do that...

Or for checking that a date value is greater or less than another date
value e.g. today's date...

Or, even more importantly, to validate that mandatory fields actually do
contain a value...
--
http://www.markrae.net
I would have to agree with Peter on this one. For the reason that the
submittal of the form may be from a source that has script disabled, or
posted from another screen, or something similar....the client-validation
would never run, yet the postback would...or maybe the postback wouldn't
with script turned off....hmm...I'll check it out.

HTH,
Mythran
Jun 11 '07 #5


"Mark Rae" <ma**@markNOSPAMrae.netwrote in message
news:Ov**************@TK2MSFTNGP03.phx.gbl...
"Peter Bradley" <pb******@uwic.ac.ukwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
>I'm sure there are good reasons for doing this client side, but I've
never found one.

To minimise the number of round trips to the server and back...
>Data entry validation always needs to be done server-side when the user
submits the form: so why not just settle for that and do the validation
server side? You're doing a postback anyway, so there's no extra time
taken worth talking about.

Not true at all...

E.g. if you are writing a subscription site where users need to register,
and one of the criteria for registration is that registrants needs to be
at least 18 years old, then a simple client-side validation is perfectly
fine - there's no need for a round trip just to do that...

Or for checking that a date value is greater or less than another date
value e.g. today's date...

Or, even more importantly, to validate that mandatory fields actually do
contain a value...
--
http://www.markrae.net
Glad I double-checked. A form submittal is caused (usually) by a "submit"
input button and not through script, unless you are using a control that has
the AutoPostBack set to True or a LinkButton (or similar) control, which
then uses script and will not perform a postback if script is disabled on
the client...

HTH,
Mythran
Jun 11 '07 #6
On 11 Jun., 12:09, neeraja...@gmail.com wrote:
hi i'm new to .net field, i'm developing one application using ASP.NET
and C#.NET in that i get one problem that is how to validate user
entered date and time formate, for this problem wheather i have to use
RegularExpressionValidator or any other Code, Give the response soon
i'm waiting for reply
Use the RegEx-validator, e.g.:

<asp:RegularExpressionValidator ID="myRegExValidator" runat="server"
ControlToValidate="myBtn" ErrorMessage="Wrong input, you need to write
a date in format dd/mm/yyyy" ValidationExpression="^\d{1,2}\/\d{1,2}\/
\d{4}$" ></asp:RegularExpressionValidator>

You can find examples of different date and time expressions here:

http://regexlib.com/(A(eJE4ziet-S-qk...4&categoryId=5

Regards;)

Jun 11 '07 #7

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Bharathi Kumar | last post: by
9 posts views Thread by rn5a | last post: by
8 posts views Thread by =?Utf-8?B?bWlrZWc=?= | last post: by
reply views Thread by Saiars | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.