|
-
Jul 12th, 2008, 10:18 AM
#1
Thread Starter
Hyperactive Member
[RESOLVED] [2005] Get Attributes ID from ASP.NET to Javascript
Hi,
I have created a list of input delete buttons in server side eg.
<input type="Button" value="Delete" id="DeleteButton" >
I want to put confirmation but somehow I need to pass in 1 value from server side in order for me to process? Any suggestion on how should I go about doing that?
var confimDelete = confirm("Confirm delete?");
if (confimDelete == true) {
window.location.href = "AnotherForm.aspx?ID=" + howtoretrievefromServer();
} else {
window.event.returnValue = false;
}
-
Jul 12th, 2008, 02:25 PM
#2
Re: [2005] Get Attributes ID from ASP.NET to Javascript
When you call this javascript function, pass the ID.
onclick="ConfirmDeletion(theIDofTheItemYouAreDeleting);"
Then use that in your window.location.href.
-
Jul 13th, 2008, 09:21 AM
#3
Thread Starter
Hyperactive Member
Re: [2005] Get Attributes ID from ASP.NET to Javascript
lol, this works well and it only uses 1 function. I think until so complicated Nevertheless, thanks for your help
-
Jul 14th, 2008, 12:55 PM
#4
Re: [RESOLVED] [2005] Get Attributes ID from ASP.NET to Javascript
Not sure I understood, did that solve your problem or give you an idea as to what you can do to fix the problem?
-
Jul 22nd, 2008, 07:26 AM
#5
Thread Starter
Hyperactive Member
Re: [RESOLVED] [2005] Get Attributes ID from ASP.NET to Javascript
I use ur code to solve my problem
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|