Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

is it possible to call a subroutine within an asp page?

Status
Not open for further replies.

wvdba

IS-IT--Management
Jun 3, 2008
465
US
hi,
is it possible to call subroutine within an asp page that's being used multiple times depending on a selected function?
what's the syntax?
thanks.
 
Yes, it is possible. Can you please provide more information about your problem.

Here is a very basic example.
Code:
<%
public sub PrintTXT(Content)
response.write Content
end sub
%>
<br />
<%
call PrintTXT("Content1")
%>
<br />
<%
call PrintTXT("Content2")
%>
<br />
<%
call PrintTXT("Content3")

%>

Babloome
 
thanks so much, babloome.
i kind of was giving up on answer for this one. it's been posted for almost a week. i appreciate your reply. basically, my asp page has 3 tasks that are organized into 3 if statements. each one would call a drop-down load routine. i don't want to repeat this loading of the drop-down box 3 time. instead, i would like to call a sub to do it. your solution is the answer to my problem.
thanks again.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top