View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Thomas Ramel Thomas Ramel is offline
external usenet poster
 
Posts: 70
Default Looping Question (I think?)

Grüezi MWS

MWS schrieb am 27.10.2004

What I need to do is, copy the number in column B down until
a different number is displayed, and then copy the new number down, etc. (ie
in the example below,for the Banana and Carrot entries, the corresponding
values in column B would be 548)

(Column A) (Column B)
Banana 548
Banana
Banana
Carrot
Carrot
Carrot
Carrot
Apple 635
Apple
Apple
Pear 589
Pear

Any and all assistance would be greatly appreciated.


Assuming your first value is in B1 then follow these steps:

Mark column B completly -- F5 -- [Contains...] (butteon bottom left of
the window) -- [x] empty cells -- [OK]

Now write the following formula:

=B1

and press Ctrl+Return

Mark column B completly again -- Copy -- Rightclick - insert values (or
similar) -- [x] values -- [OK]

--
Regards

Thomas Ramel
- MVP for Microsoft-Excel -

[Win XP Pro SP-1 / xl2000 SP-3]