View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Tushar Mehta Tushar Mehta is offline
external usenet poster
 
Posts: 1,071
Default VBA beating me up.....again

Here's a non-programmatic solution.

In F1 enter the formula =IF(B10,$A1,IF(B20,$A2,IF(B30,$A3,"")))
Copy F1 to G1:H1

In F2 enter the formula =IF(COUNTIF(F$1:F1,$A$1)<B$1,$A$1,IF(COUNTIF(F
$1:F1,$A$2)<B$2,$A$2,IF(COUNTIF(F$1:F1,$A$3)<B$3,$ A$3,"")))

Copy F2 to G2:H2.

Copy F2:H2 as far down as needed. You should see at least one empty
cell in each column.

--
Regards,

Tushar Mehta, MS MVP -- Excel
www.tushar-mehta.com
Excel, PowerPoint, and VBA add-ins, tutorials
Custom MS Office productivity solutions

In article ,
says...
I should just give up.....

I have a sequential list of items that contains a variety of integers
such as:

A 4 3 0
B 0 1 5
C 2 0 2

We'll say A is in cell A1, the 5 in cell D2, etc.....

Which has to produce three columns of letters A-C with the correct
number of letters. It looks like:

A A B
A A B
A A B
A B B
C B
C C
C

In my spreadsheet the three columns are in F, G, and H.

First column has the 4 A's, 0 B's and 2 C's, etc.

The A through C is constant of course, but the column of numbers next
to it constantly changes. I want the list to change also. I won't
bother posting the VBA I have tried to come up with because it's all
garbage.

Thanks in advance.


---
Message posted from
http://www.ExcelForum.com/