#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11
Default Fill and expand

I have information exported from an accounting system into an Excel
spreadsheet. The export has 3 columns; the first column contains the value of
the first data of the range; the second column contains the end value of the
range; the third column shows a percentage rate applicable to all values
within the range. e.g

C00123 C00125 15%
C00128 C00130 100%

Note there is a gap between the end value at column 2 in row 1 and the next
value in column 1 of row2. The intervening range has a default percentage
rate of 0%.

Is there a way to expand and fill the/a spreadsheet so that the result looks
like this:

C00123 15%
C00124 15%
C00125 15%
C00126 0%
C00127 0%
C00128 100%
C00129 100%
C00130 100%
C00131 0% et seq

I would greatly appreciate any help.
--
Geoff
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Fill and expand

One play which should deliver it for you ..

Assume source data in cols A to C, from row1 down
Put in D1: =SUBSTITUTE(A1,"C","")+0
Copy D1 to E1, fill down to last row of source data

Then place
In F1: =$D$1+ROWS($1:1)-1
In G1: ="C"&TEXT(F1,"00000")
In H1, array-entered (press CTRL+SHIFT+ENTER to confirm the formula):
=IF(ISNA(MATCH(1,(F1=D$1:D$100)*(F1<=E$1:E$100),0 )),0,INDEX(C$1:C$100,MATCH(1,(F1=D$1:D$100)*(F1<= E$1:E$100),0)))
Format H1 as percentage to taste. Adapt the ranges in H1 to suit your actual
extents. Then select F1:H1, fill down as far as required. Cols G & H should
return the exact results that you seek.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Geoffric" wrote:
I have information exported from an accounting system into an Excel
spreadsheet. The export has 3 columns; the first column contains the value of
the first data of the range; the second column contains the end value of the
range; the third column shows a percentage rate applicable to all values
within the range. e.g

C00123 C00125 15%
C00128 C00130 100%

Note there is a gap between the end value at column 2 in row 1 and the next
value in column 1 of row2. The intervening range has a default percentage
rate of 0%.

Is there a way to expand and fill the/a spreadsheet so that the result looks
like this:

C00123 15%
C00124 15%
C00125 15%
C00126 0%
C00127 0%
C00128 100%
C00129 100%
C00130 100%
C00131 0% et seq

I would greatly appreciate any help.
--
Geoff

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11
Default Fill and expand

Superb reply, Max. It works perfectly. May I ask a supplementary question?
Instead of listing out the info as per your reply, is it possible to allocate
the data in column 3 of the original export (without expanding it) to a list
of data, by a formula that refers to the original export? i.e. if I had a
list of just data such as:

C00123
C00124
C00125
C00126
C00127
C00128

C00129
C00130
C00131,


I could use a formula copied down in the next column that would refer to the
original export, and pick up the 3rd column data, including the data not
shown therein (i.e. the 0% allocated to the "invisible" ranges between the
ranges shown) to arrive at:


C00123 15%
C00124 15%
C00125 15%
C00126 0%
C00127 0%
C00128 100%
C00129 100%
C00130 100%
C00131 0% et seq


Thank you for any help you can offer.

Regards,


--
Geoff


"Max" wrote:

One play which should deliver it for you ..

Assume source data in cols A to C, from row1 down
Put in D1: =SUBSTITUTE(A1,"C","")+0
Copy D1 to E1, fill down to last row of source data

Then place
In F1: =$D$1+ROWS($1:1)-1
In G1: ="C"&TEXT(F1,"00000")
In H1, array-entered (press CTRL+SHIFT+ENTER to confirm the formula):
=IF(ISNA(MATCH(1,(F1=D$1:D$100)*(F1<=E$1:E$100),0 )),0,INDEX(C$1:C$100,MATCH(1,(F1=D$1:D$100)*(F1<= E$1:E$100),0)))
Format H1 as percentage to taste. Adapt the ranges in H1 to suit your actual
extents. Then select F1:H1, fill down as far as required. Cols G & H should
return the exact results that you seek.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Geoffric" wrote:
I have information exported from an accounting system into an Excel
spreadsheet. The export has 3 columns; the first column contains the value of
the first data of the range; the second column contains the end value of the
range; the third column shows a percentage rate applicable to all values
within the range. e.g

C00123 C00125 15%
C00128 C00130 100%

Note there is a gap between the end value at column 2 in row 1 and the next
value in column 1 of row2. The intervening range has a default percentage
rate of 0%.

Is there a way to expand and fill the/a spreadsheet so that the result looks
like this:

C00123 15%
C00124 15%
C00125 15%
C00126 0%
C00127 0%
C00128 100%
C00129 100%
C00130 100%
C00131 0% et seq

I would greatly appreciate any help.
--
Geoff

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Fill and expand

Superb reply, Max. It works perfectly.
Welcome, glad it did.

May I ask a supplementary question?

Usually best to do this as a fresh posting,
for maximum visibility to all possible responders
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---


  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11
Default Fill and expand

Thanks for the advice. I will post a new query.
--
Geoff


"Max" wrote:

Superb reply, Max. It works perfectly.

Welcome, glad it did.

May I ask a supplementary question?

Usually best to do this as a fresh posting,
for maximum visibility to all possible responders
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---





Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Fill in form to type Item descrictions and costs and fill in funct cradino Excel Worksheet Functions 0 July 16th 06 08:44 PM
Edit Fill Series - How do I fill using minute increments IUnknown Excel Discussion (Misc queries) 1 January 29th 06 12:50 PM
I have a list of data, fill in the gaps. FILL function won't work Triv Excel Discussion (Misc queries) 1 September 17th 05 02:33 PM
The fill feature in Excel that gives option to fill or copy KAHelman New Users to Excel 1 July 29th 05 07:47 PM
How to fill colour in Excel, it appers No fill in my computer? bede Excel Discussion (Misc queries) 1 June 11th 05 03:27 AM


All times are GMT +1. The time now is 06:36 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"