View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
excel-ant excel-ant is offline
external usenet poster
 
Posts: 26
Default Parse cells with line breaks

Hi Jo,

You can use the following Macro to fill down any empty cells with the
value immediately above
==========================================
Sub FillDown()

Dim cl As Range

For Each cl In Selection
If cl = "" Then cl.Value = cl.Offset(-1, 0).Value
Next

End Sub
===========================================
Anthony
http://www.excel-ant.co.uk



jo wrote:

I have a spreadheet with multiple columns of data and some with line
break characters within the cells.

I have an identifier in the left column, A, and the cells with line
breaks inside to the right. For example,

ID Books

1 The Hobbit
Driving Miss Daisy
2 Only One book

3

4 First Book for id 4
Second book for id 4
Third book for id 4





I need to move this information to another sheet such that the ID is
repeated for each item in the books column. The number of rows per ID
would equal the number of line breaks + 1. How can I do this?