fb:porticula NoPaste
UDT - SUB
Uploader: | ThePuppetMaster |
Datum/Zeit: | 30.10.2007 05:01:16 |
[code]private type UDT_Type
Val1 as String
Val2 as String
end type
Declare Sub Main()
Declare Sub UDT_Add(BV_UDT_D() as UDT_Type, BV_UDT_C as Long, ByVal V_Val1 as string, ByVal V_Val2 as String)
Main
Sub Main()
Dim UDT_D() as UDT_Type
Dim UDT_C as Long
Print "Befor: " & UDT_C
UDT_Add UDT_D(), UDT_C, "Value1", "Value2"
Print "After: " & UDT_C
end Sub
Sub UDT_Add(BV_UDT_D() as UDT_Type, BV_UDT_C as Long, ByVal V_Val1 as string, ByVal V_Val2 as String)
BV_UDT_C = BV_UDT_C + 1
Redim Preserve BV_UDT_D(BV_UDT_C) as UDT_Type
With BV_UDT_D(BV_UDT_C)
.Val1 = V_Val1
.Val2 = V_Val2
end with
end sub
[/code]