List with empty spaces

zorans

New Member
Joined
Nov 14, 2003
Messages
32
Hi
I have list
A1=Peter
A2=0
A3=0
A4=John
A5=0
A6=0
A7=0
A8=0
A9=George

I want to B column looks like:
B1=Peter
B2=Peter
B3=Peter
B4=John
B5=John
B6=John
B7=John
B8=John
B9=George

Can anyone help?

Best regards
 

Some videos you may like

Excel Facts

What do {} around a formula in the formula bar mean?
{Formula} means the formula was entered using Ctrl+Shift+Enter signifying an old-style array formula.

Jon von der Heyden

MrExcel MVP, Moderator
Joined
Apr 6, 2004
Messages
10,806
Office Version
  1. 365
Platform
  1. Windows
Hi,

In B1: =A1
In B2: =IF(A2=0,B1,A2) copied down to end of range.

Regards,
Jon
 

Watch MrExcel Video

Forum statistics

Threads
1,118,075
Messages
5,570,051
Members
412,309
Latest member
essobsan
Top