LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 38
Default Transferring ranges to/from arrays

What is the most efficient way to load data from a sheet range into an array
so I can
pass the data to a DLL function? And, to transfer the results back into
another sheet range?

That is, I want to do something like this

Sub mySub

inargs(0) = Range("x").value
inargs(1) = Range("y").value
inargs(2) = Range("z").value
ec = theDllFunction(inargs(0), outargs(0)

Range("a").Value = outargs(0)
Range("b").Value = outargs(1)
Range("c").Value = outargs(2)

End

The above works, but if the cells named x, y, z, and those named a, b, c,
are in a contiguous ranges it seems there must be
a more efficient way to do this.


TIA

Ed



 
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
Formulas in arrays and named ranges Babymech Excel Discussion (Misc queries) 2 July 21st 08 04:16 PM
Ranges and Arrays in Excel VBA a.riva@UCL Excel Worksheet Functions 15 October 27th 07 12:15 AM
comparing ranges/arrays asaylor Excel Worksheet Functions 7 June 13th 06 11:53 PM
Comparing two arrays/ranges SpiderBoy Excel Programming 0 July 25th 03 07:58 PM


All times are GMT +1. The time now is 07:42 AM.

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"