LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 38
Default keep recursion result (a dynamic array) without using global variable

well, thanks. I just take the parameter way to deal with it and it
works well.

Another confusion without too much relation to the above is when I
define a function with a string parameter, can I give an elememnt from
a variant to that parameter? It seems always showing me the "ByRef
argument type mismatch" msgbox.

How do I force the element from a variant be string type?

Here is what the function seems like
___________________________
sub myFunc(str as string)
....
end sub
----------------------------------------------

and here is what I use to call myFunc
____________________________
Dim path() variant
Redim path(1 to 3, 1 to 100)
....
Redim Preserve path(1 to 3, 1 to 20)
myFunc(path(1, 2))



thanks!
lvcha

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Global variable dhstein Excel Discussion (Misc queries) 2 October 30th 09 01:03 PM
Global Variable dhstein Excel Discussion (Misc queries) 4 July 26th 09 05:10 PM
Global Variable Patrick Simonds Excel Programming 8 October 6th 05 12:39 AM
why is it saying sheetcnt is "variable not defined" how to do a global variable to share over multiple functions in vba for excel? Daniel Excel Worksheet Functions 1 July 9th 05 03:05 AM
Declaring variable as a dynamic array? aiyer[_44_] Excel Programming 1 August 17th 04 11:01 PM


All times are GMT +1. The time now is 08:21 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"