Array Help

S

steve yuchs

I currently am using excel to gather data from an
instrument that is used in the lab. I can paste the
results from the instrument program into an excel sheet
using the paste special link, and the instrument program
will automatically update the sheet using a DDE. The
problem is it keeps overwriting the same cell (where the
pastespecial link is placed). The instrument program is
writing the data out in an array, and every time I try to
do anything to the array, it says you cant modify it. I
would like to just grab the first line of the array, and
move it to another worksheet. Then when the DDE updates, I
would like to have the second worksheet move down a row and
write the next piece of data. Can someone please help an
inexperienced excel user out. Thanks in advance.
 
T

Tom Ogilvy

Dim rng as Range, rng1 as Range
set rng = worksheets("Sheet2").cells(rows.count,1).End(xlup)(2)
set rng1 = Worksheets("Sheet2").Range("A5:M5")
rng.Resize(1,rng1.columns.count).Value= rng1.Value
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top