Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

FILL VALUES FROM PREVIOUS LINES

Status
Not open for further replies.

villica

Programmer
Joined
Feb 25, 2000
Messages
332
Location
CA
I have a file that looks as follow

pn date vendor lineno PO
ABC 12/01/02 00654 1 892
12/02/01 000352
DEF 11/11/02 11111 1 99
1/8/03 99


My question is there a way to update this file with the values from the previous lines where there is BLANK

pn date vendor lineno PO
ABC 12/01/02 00654 1 892
ABC 12/02/01 000352 2 892
DEF 11/11/02 11111 1 99
DEF 1/8/03 99 2 99


thanks villica
 
Select the cells in the pn column, from the SECOND cell (which should be blank) on down.

Hit Edit-Go to-Special, Blanks.

Type =A2
(where A2 is the first cell under the pn heading--the one you did not select)

Hit Ctrl+Enter.

Now select all those cells again, Copy. Edit-Paste special, Values, Ok.

For your lineno column, the formula will be a little diff:

Type =D2+1
(where D2 is the first cell under the lineno heading--the one you did not select
Anne Troy
Word and Excel Macros
Coming soon: wX
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top