-
Submit problem
Hello everybody,
I have two buttons(images) "Save" and "Delete" in my aspx file. On the click of "Save" and "Delete" form should be submitted and related operations should be performed. "Save" is working fine. But when I write code for "Delete", how do I know whether form is submitted by clicking "Save" or "Delete".
Thanks
-
Re: Submit problem
Just write the code to perform your operations in the delete button's click event. You don't need to worry about the form being "submitted" here. Are you facing a problem with this?
-
Re: Submit problem
I do not have buttons, rather I have images for "Save" and "Delete" and I explicitly submit form on the click of these images.
-
Re: Submit problem
You could use image buttons then.
-
Re: Submit problem
Thanks mendhak. Where can I find image buttons ? Can we provide all the styles etc. to the image buttons which we apply on normal images ?
-
Re: Submit problem
It's under the Web Forms controls tab in your toolbox bar.
Right under link button. And yes you can apply styles on it.
-
Re: Submit problem
Once you have added a image button you can do the follwing:
Code:
Private Sub ImageButton1_Click(ByVal sender As System.Object, ByVal e As System.Web.UI.ImageClickEventArgs) Handles ImageButton1.Click
'code here to save/delete stuff
End Sub
Hope that helps.
Woka