You have to submit the page back to the server in order to call a server-side ASP function or sub.
So, for instance, you could do something like this:
<%
dim strAction
strAction = Request.form("hdnAction"
if UCase(strAction)="ADD" then
call AddNew()
end if
sub AddNew()
...
end sub
%>
<script language="javascript">
function setAction(){
document.frmTest.hdnAction.value="Add";
document.frmTest.submit();
}
</script>
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.