View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Pete_UK Pete_UK is offline
external usenet poster
 
Posts: 8,856
Default Create alternate line of data

You can't do this with a formula, as a formula cannot insert rows -
you would need a macro to do it.

An alternative approach you might be able to take would be to add some
formulae at the bottom of your data, fix the values, and then sort the
table. For example, if your data is currently on rows 2 to 30, then in
row 31 you could have these formulae and values:

A31: =A2&"_OAK"
B31: =B2
C31: OAK
D31: oak.jpg

Then you could copy A31:D31 into rows 32 to 59, and then highlight
A31:D59, click <copy, then Edit | Paste Special | Values | OK and
<Esc. Then sort the complete table using column A as the sort field.

Hope this helps.

Pete

On Jan 17, 3:13*pm, Excel Helps
wrote:
Hello again,
Is it possible to create alternating lines of data using a function, based
on a preceding line?
I need to add simaler products underneath each line of existing data to add
the wood type oak.

Code * *Name * *Wood * *Wood_Image
A1 * * *Chair * Pine * *pine.jpg

A2 * * *Chair * Pine * *pine.jpg

This line to be added inbetween A1 and A2
A1_OAK * * Chair * * * * Oak * * * * *oak.jpg

Thanks.