troubleshooting Question

how to save a text field as null if missed

Avatar of shpresa
shpresaFlag for United States of America asked on
Microsoft SQL ServerC#ASP.NET
8 Comments1 Solution336 ViewsLast Modified:
Hello Experts

I have a text field that can accept a range values from 0 - 10
If the question is missed it is stored a 0 value in the database, and I want know if I have a missed question or a zero value.

How can I save that field to be 'null' if missed.

This is how I have it currently.

            cmd.Parameters.Add(new SqlParameter("@Times", txtTimes.Text.Trim()));

on save click button.
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 8 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 8 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros