Author: kdickie | Posted on: 5/7/2010 6:10:34 PM | Views : 497

Hi Everyone,
I have a form where a user enters in a Tag ID number into a text box (txtTagNumber) and then clicks a Submit button (btnTagNbr). I need to take that Tag ID number, query the database to see if there are any records in the db for that Tag ID, then return the count of records in a popup confirmation window and then ask the user if they wish to proceed. If they click OK, then I redirect to a new page.
I'm having trouble with my Tag ID number (txtTagNumber), it is always null. 
In this line: connection2data.Parameters.AddWithValue("@StateTag", txtTagNumber.Text)
the txtTagNumber.Text value is always null. In testing if I hard code a Tag number in here like this:
                   connection2data.Parameters.AddWithValue("@StateTag", "B44921")
I get a value from the database. I don't why ...

Go to the complete details ...