Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

web developer error

Status
Not open for further replies.

davedizzle15

Technical User
Feb 28, 2007
14
US
i have a webpage with an update button at the bottom that saves all the information from the page's text boxes. I have a checkbox at the bottom of this same page that the user checks when they are done with the page. So when the UPDATE button is clicked, i want to run a few if statements. Basically i want to know if it is possible to run scripts BEFORE any of the Update panel stuff? The main error im getting is in the VB code. if the checkbox name is done1 i try to type something like:

IF done1 = true

but it always tells me that done1 is not declared.

can anyone help?
 
oops sorry, it should read IF done1.text = true......

done1 is the ID of the checkbox
 
Checking for the Text property won't tell you if the CheckBox is checked. For that, you should use the Checked property.


____________________________________________________________
Mark,
[URL unfurl="true"]http://aspnetlibrary.com[/url]

Need help finding an answer? Try the Search Facility or read FAQ222-2244 on how to get better results.
 
thanks for the suggestion. i see what you are saying. but my main issue with the vb code is that no matter what i get an error saying that "done1 is not declared".
 
Imports System.Windows.Forms





Partial Class newedit
Inherits System.Web.UI.Page
Protected Sub DropDownList3_SelectedIndexChanged(ByVal sender As Object, ByVal e As EventArgs) Handles DropDownList3.SelectedIndexChanged
MultiView1.ActiveViewIndex = Integer.Parse(DropDownList3.SelectedValue)
End Sub

Protected Sub UpdateButton_Click(ByVal sender As Object, ByVal e As System.Web.UI.ImageClickEventArgs)
System.Threading.Thread.Sleep(3000)
End Sub
End Class
 
That is the code behind not the page. Also, there is no reference to the "IF done1 = true" code in this example so that can't be all of your code anyway.

If you want to get any help from these forums you will have to provide any relevant information and as I've said to you before you haven't responded to any of the posts you have made to either thank the person who offered you the help nor to say whether it worked or not. If you want to get help from these forums, I suggest you read the FAQ in my signature (especially items #15 and #16).





____________________________________________________________
Mark,
[URL unfurl="true"]http://aspnetlibrary.com[/url]

Need help finding an answer? Try the Search Facility or read FAQ222-2244 on how to get better results.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top