Logo
Home Cart [Log In] About Us Contact Us

Object Reference

xf_GeneralGeneral Functions

Public Function subst_array (
text As String,
ArrayVar As Variant
) As String

Parameter substitution: substitute the values in the passed array for %1, %2 etc in the string

text as String

The string value contining placeholders such as %1, %2, etc

ArrayVar as Variant

Array of values to be inserted into the string

Call Template:

Dim s As String
s = xf.Gen.subst_array(text, ArrayVar)

See Also:

Example 1:

Dim arr(3) as String
arr(1) = "John"
arr(2) = "river"
arr(3) = "jump"
Debug.Print subst_array("Hi, %1, please %3 to the %2", arr)
prints: Hi, John, please jump to the river
Contact Us :: About Us :: Policies :: email: infspamo@arrospamw-of-tispamme.com    © 2012 Arrow Of Time Pty Ltd