Thread: arrays in excel
View Single Post
  #4   Report Post  
Leo Heuser
 
Posts: n/a
Default

Hi Dan

One way:

In Sheet2 B1:

=IF(COLUMN()-COLUMN($B1)+1<=COUNTIF(Sheet1!$A$1:$A$100,$A1),
OFFSET(Sheet1!$B$1,MIN(IF((Sheet1!$A$1:$A$100=$A1) *(COUNTIF(
OFFSET(Sheet1!$A$1,,,ROW(Sheet1!$A$1:$A$100)),$A1) =COLUMN()-
COLUMN($B1)+1),ROW(Sheet1!$A$1:$A$100)-1)),0),"-")

Entered as one line with <Shift<Ctrl<Enter, also if edited later.

Copy B1 to the right as far as necessary with the fill handle (the
little square in the lower corner of the cell)

Copy the selection down with the fill handle.

--
Best Regards
Leo Heuser

Followup to newsgroup only please.

"Dan" skrev i en meddelelse
...
Sorry, I wasn't very clear, what in need is this:

A1:021-310L B1:107803
A2:021-310L B2:109851
A3:021-310L B3:109551

so when i enter in a1 on a seperate sheet i would get this:

A1:021-310L B1:107803 C1:109851 D1:109551

Thanks Again!