#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2003
    Posts
    118
    Rep Power
    12

    Calling function with multiple return values??


    I am new to VB. I need to call a function that returns several values. What is the syntax? Do I do

    [val1, val2, ...] = function()

    Or does it return a structure and then I do

    v = function()

    at which point I have v.val1, v.val2,...

    The documentation I have is quite pathetic so I know nothing about the function other than that it returns a bunch of values.

    Thanks,

    Brian
    Brian Huether
    www.guitar-dreams.com
  2. #2
  3. No Profile Picture
    Overly white
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2003
    Location
    Fresno, CA
    Posts
    83
    Rep Power
    12
    I would say that it is going to return an array of values. Do you know if all the values are going to be the same such all longs or all strings? If they are going to be different, some longs, some strings, etc. then you will need to use a variant.


    Code:
    Dim foo as variant
    
    foo = function()

IMN logo majestic logo threadwatch logo seochat tools logo