Public Function VariantMatrixToString( _ ByRef vLines() As Variant _ , ByVal vColumnSeparator As Variant _ , ByVal vRowSeparator As Variant _ ) As String
Assuming Static avarTable(0 To 2, 0 To 2) As Variant ' Column--v v--Row avarTable(1, 1) = "From" avarTable(2, 1) = "feet" avarTable(1, 2) = "To" avarTable(2, 2) = "meters" for example ? VariantMatrixToString(avarTable(), " ", vbCrLf) From feet To meters ? VariantMatrixToString(avarTable(), "=", "&") From=feet&To=metersSee also:
StringToVariantMatrix Function (near inverse) VariantVectorToString FunctionvLines: Two-dimensional array of Variants that will be assembled into a String. Within this array, dimension #1 represents the Column and dimension #2 represents the Row. This is because the number of rows changes most frequently and the upper bound of the last dimension (representing the row) can be re-dimensioned directly by Visual Basic.
Copyright © 1999-2005 Entisoft