473,508 Members | 2,227 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Validate FormView fields C#

Title says it ... my C# web application uses a number of FormViews that are
inserted/updated/deleted via stored procedures.

Is there a way thru C# coding (example?) to validate a date field as valid
input before inserting/updating? Test the length of a varchar/char field?
Validate an int field as valid numeric input (no alpha) ... and so on?

I would like to do this validation before the stored procedures fire
(perhaps stopping), of course so the user does not see the cryptic messages
that come back by default.

It would be nice to see some C# examples or the specifics on another
workarounds. Thanks to all you pros for reading.
Jun 27 '08 #1
0 1382

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
6154
by: Ottar | last post by:
I have a few numeric fields, and when I update i get the error: "Input string was not in a correct format". Next line:" System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer&...
1
1256
by: TdarTdar | last post by:
I wanted to add three columns up on the form and run some logic to fill in the third but not sure how to call the field names in the formview control. Dim Girth As Integer Elenght =...
0
2179
by: Metal2You | last post by:
I'm working on an ASP.NET 2.0 application in Visual Studio 2005 that accesses a Sybase database back end. We're using Sybase SQL Anywhere 9.0.2.3228. I have installed and registered the Sybase...
2
8732
by: P. Yanzick | last post by:
Hello, I am creating an edit template for a FormView control, changing one of the textboxes to a dropdown box. The dropdown will be populated from a simple table with the primary key, and a...
7
4337
by: Lorenzino | last post by:
Hi, I have a problem with bindings in a formview. I have a formview; in the insert template i've created a wizard control and inside it i have an HTML table with some textboxes bound to the...
0
1091
by: boomhauer | last post by:
Hi, Im using a lot of formview's in my asp.net app, and it gets a bit frustrating to tie a datasource to the formview and have it generate the labels and fields for the datasource, to only then...
1
1359
by: Uriah Piddle | last post by:
Hi, I have a FormView where nothing gets rendered past the opening <ItemTemplatetag. The FormView Header renders but nothing else. If I put garbage in an Eval statement, no errors are raised and...
0
1641
by: John Mason | last post by:
Hi, I've been trying for most of the day to get a FormView control to work. I would like to display a single record, based on a unique user id (loginid), which I am retreiving from a cookie. No...
0
1086
by: COHENMARVIN | last post by:
I have a sqldatasource and a formview. I bind the formview to the sqldatasource, and hope that automatically the fields of the select statement in the datasource will appear in the itemtemplate of...
0
7132
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7401
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
5640
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5059
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4720
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3211
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3196
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1568
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
773
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.