bResult = Call Sample("5")
Msgbox "Return value of Sample function " & bResult
<font class="small">Code:</font><hr /><pre>
Sample = InParameter
I would suggest you to have a look in to the VBScript help files before attempt.
Each function can be set up to return a value. Your calling script can store that value into a variable that you can use elsewhere (like I do below with x, y, z, and q, or you can use it in other ways, such as nesting one function inside another like I do below with the first line of code:
<font class="small">Code:</font><hr /><pre>msgbox fTranslate(fMultiply(fAdd(2))) 'Twenty
x = fAdd(3)
y = fMultiply(x)
z = fTranslate(y)
msgbox z 'Twenty Four
q = fTranslate(fMultiply(fAdd(4)))
msgbox q 'I Cannot Translate 28
fAdd = inNumber +3
fMultiply = inNumber*4
If inNumber = 20 Then
fTranslate = "Twenty"
ElseIf inNumber = 24 Then
fTranslate = "Twenty Four"
fTranslate = "I cannot translate " & inNumber
End Function</pre><hr />
Hope that helps.
"The last 10% of any software project will take 90% of the budgeted time. The first 90% will take the other 90%"