Morgoth
03-10-2003, 04:39 AM
Well, I figured ASP/VB ment some people in here might know Vbscript.
I am having a problem with my lack of VBscript knowledge and basically, what I want to do is probibly not possible with VBscript, but is with javascript.
I want to have it so, when a <a> tag (text link) is clicked, it will execute "Sub delete_onClick". It then asks itself, if it equals 6 ("yes"), then it will link to a link in which I need a Variable to be taken out of a "value" or something and placed in the spot of "VarID".
Can I do this with a text link (<a> tag)? Can I do this with VbScript?
<script language="VBScript">
Sub delete_onClick
If MsgBox("Are you sure you wish" & vbCrLf & "to delete this comment?",52,"Delete Comment?") = "6" Then
window.location="delete.asp?type=delete&ID=" & VarID & "&delete=true"
End If
End Sub
</script>
<a href="#" name="delete" value="MyID">
I am having a problem with my lack of VBscript knowledge and basically, what I want to do is probibly not possible with VBscript, but is with javascript.
I want to have it so, when a <a> tag (text link) is clicked, it will execute "Sub delete_onClick". It then asks itself, if it equals 6 ("yes"), then it will link to a link in which I need a Variable to be taken out of a "value" or something and placed in the spot of "VarID".
Can I do this with a text link (<a> tag)? Can I do this with VbScript?
<script language="VBScript">
Sub delete_onClick
If MsgBox("Are you sure you wish" & vbCrLf & "to delete this comment?",52,"Delete Comment?") = "6" Then
window.location="delete.asp?type=delete&ID=" & VarID & "&delete=true"
End If
End Sub
</script>
<a href="#" name="delete" value="MyID">