Good morning,
I'm having a bit of a problem getting this last piece to work. Basically I have a UDF called Route_Module which can take locations, and passes the data to a mapping program which can then return the driving distance, or driving time of the points you give it. I am using a Paramarray in this UDF to allow the user to enter a variable amount of locations. This function is working great as a UDF entered into a cell, no issue here (I posted the code below for your reference).
Now, what I would like to do is be able to use this UDF within VBA for calculation purposes. I have created a test function to try and achieve this. Instead of the user having to pass each location in as a separate array item, the list of locations is going to be concatenated in one cell, separated by commas. What I have tried to do is use "Split" to create an array from the comma delimited list, however if I pass this array into my UDF, I can't get it to work.
What I am struggling with is passing the array created in the "TEST" function, into the Route_Module function.