Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
OK, I accept that it isn' t possible. I 'broke up' the type into its
components to pass it. NickHK wrote: I get a compile error on such a set up, as you cannot use user defined types as arguments or return values in public routine. Your type is private, so the Update routine cannot see it. Maybe move to using a Class instead. NickHK "RocketMan" wrote in message oups.com... I get the compile error: ByRef Argument Type Mismatch at the line Call Upate(itercount, a(i)) and it doesn't make sense to me. I am passing only one element of an array and the types seems fine to me. HELP Here is the example: Private type Iteration Name as string count as integer end type private type j domain as string it() as Iteration end type public function start() dim i, itercount as integer dim a(500) as j itercount = Worksheet("iters").Range("c1") for i = 0 to 499 redim a(i).it(itercount ) as Iteration Call Update(itercount, a(i)) next end function ' NOTE this function is in a separate ( .xla sheet) Module Public Function Update(byval icount as long, byref DomIters as j) ' stuff done in here end function |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
"Type mismatch" when I try to fill an Array variable with "+" | Excel Discussion (Misc queries) | |||
Error Handling to mitigate "Run Time Erorr 13 Type Mismatch" | Excel Programming | |||
"ByRef argument type mismatch" Error | Excel Programming | |||
ByRef argument type mismatch error? | Excel Programming | |||
"FIND" generates "Type mismatch" error | Excel Programming |