<% @LANGUAGE = VBScript %> <% Option Explicit %> Function Example <% Function add_num (num1, num2) ' Adds any two numbers add_num = num1 + num2 End Function %>

Invoking a function to add 2+3.

<% Dim sum sum = add_num(2,3) Response.write("Sum of 2 and 3 is " & sum & "
") %>

Function has been called.