Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello all,
I am not very experienced in excel programming. But I am wondering whether it is possible to pass a type variable as an argument to a sub or function. I am using excel 97 sr-2. thanks in advance, Koos |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Koos,
Do you mean a structure variable defined with the Type identifier? If so, then the answer is yes, you can pass types to procedures. For example, Public Type TheType X As Integer Y As Integer End Type Sub AAA() Dim T As TheType T.X = 123 T.Y = 456 BBB T End Sub Sub BBB(TT As TheType) Debug.Print TT.X Debug.Print TT.Y End Sub -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "Koos" wrote in message ... Hello all, I am not very experienced in excel programming. But I am wondering whether it is possible to pass a type variable as an argument to a sub or function. I am using excel 97 sr-2. thanks in advance, Koos |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Average: 2nd argument as a variable in another cell av(c6:c(a3)) | Excel Discussion (Misc queries) | |||
#VALUE! error - Occurs when the wrong type of argument or operand | Excel Discussion (Misc queries) | |||
Error in the argument type in french NO.SEMAINE help | Excel Discussion (Misc queries) | |||
vlookup argument type | Excel Worksheet Functions | |||
passing a variable as an argument to a function | Excel Programming |