Home » questions » urgent! vb.net?

urgent! vb.net?

2006-08-03 08:13:43, Category: Programming & Design
ok...in vb.net i have a button called btnAdd..with the text Add, when clicked the text changes to Save..i want the button to be able to click again,saves data,and change back the text...wat is the code to use when click it again... what i mean is how do u change the text back to Add sorry...i mean when i click on the button when it says save, how do u do that code?

Answers

  1. Just David

    On 2006-08-03 08:18:47


    Try something along the lines in the click event of: if btnAdd.text = "Save" Then DoStuff btnAdd.text = "Add" Else DoStuff btnAdd.text = "Save" End If