Thread: Macro Help
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Stanley Braverman Stanley Braverman is offline
external usenet poster
 
Posts: 40
Default Macro Help

I have column C and column D that contains data. I need macro that will IF
THEN with a loop till done;

1st condition. If C1 = D1 then do nothing(but look at next cells C2 and D2
etc. Etc.
2nd condition. If C1 < D1 then move cells in column C down.
(one cell at a time until condition one meet again and continue loop)
3rd condition. If C1 D1 then move cells in column D down.
(one cell at a time until condition one meet again and continue loop)

Perhaps instead of a loop maybe an input for how many rows to do

By doing this cells that are being moved will leave a bank cell in it's
place and that is what is wanted.
Example:
PS1495-15 PS1495-15
PS1495-16 PS1495-16
PS1495-17
PS1495-18 PS1495-18
PS1495-19 PS1495-19

PSJT304-16 PSJT304-16
PSJT304-17 PSJT304-17
PSJT304-18 PSJT304-18
PSJT305-15
PSJT314-01 PSJT314-01
PSJT314-02 PSJT314-02


Thanks