PC Review


Reply
Thread Tools Rate Thread

Autofull formual

 
 
Saintsman
Guest
Posts: n/a
 
      29th Jun 2009

I have 3 columns of data (ColB; ColD;ColF) Each column has a different number
of rows. In colA I calculate a % value based on how many rows of data there
are in colB ie in the table below there are 10 rows, so the values in colA
are:
first row = 10%; 2nd row = 20% etc up to 100%; if there were 20 rows then
the values would be 5%; 10%; 15% etc up to 100%.
I use the formula (ROW()-1)/(COUNT(ColB)) ColB is my named range
I want to autofill the formula to the last row of data in the adjacent column
ColA ColB
10.00% 18.26%
20.00% 11.59%
30.00% 9.69%
40.00% 6.67%
50.00% 3.53%
60.00% 1.78%
70.00% -2.19%
80.00% -3.33%
90.00% -10.90%
100.00% -14.63%
I need to do this for each column with data, so the last row needs be
specific to each column - I then produce a distribution chart for each set of
data
How do I code row()-1 in VB and then autofill the formula to run until no
data in ColB?
Any ideas?

 
Reply With Quote
 
 
 
 
Patrick Molloy
Guest
Posts: n/a
 
      29th Jun 2009

With Range(Range("B1"),Range("B1").End(xlDown)).Offset(,-1)
.FormulaR1C1 = "=(ROW()-1)/COUNT(ColB)"
end with


"Saintsman" <(E-Mail Removed)> wrote in message
news:B06062A7-B60E-4631-895B-(E-Mail Removed)...
> I have 3 columns of data (ColB; ColD;ColF) Each column has a different
> number
> of rows. In colA I calculate a % value based on how many rows of data
> there
> are in colB ie in the table below there are 10 rows, so the values in colA
> are:
> first row = 10%; 2nd row = 20% etc up to 100%; if there were 20 rows then
> the values would be 5%; 10%; 15% etc up to 100%.
> I use the formula (ROW()-1)/(COUNT(ColB)) ColB is my named range
> I want to autofill the formula to the last row of data in the adjacent
> column
> ColA ColB
> 10.00% 18.26%
> 20.00% 11.59%
> 30.00% 9.69%
> 40.00% 6.67%
> 50.00% 3.53%
> 60.00% 1.78%
> 70.00% -2.19%
> 80.00% -3.33%
> 90.00% -10.90%
> 100.00% -14.63%
> I need to do this for each column with data, so the last row needs be
> specific to each column - I then produce a distribution chart for each set
> of
> data
> How do I code row()-1 in VB and then autofill the formula to run until no
> data in ColB?
> Any ideas?
>

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Formual =?Utf-8?B?Sm9kaQ==?= Microsoft Excel Worksheet Functions 1 16th May 2007 01:03 AM
Re: WHAT DOES FORMUAL =C8+ 15 DO Bernard Liengme Microsoft Excel Misc 0 4th Jan 2007 03:38 PM
Formual =?Utf-8?B?V2lubmll?= Microsoft Excel Misc 1 13th Nov 2006 10:19 AM
Set Formual =?Utf-8?B?V2lubmll?= Microsoft Excel Misc 2 13th Nov 2006 09:47 AM
what is mean by ^ in formual =?Utf-8?B?a2hhbg==?= Microsoft Excel Programming 2 13th Oct 2005 12:16 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:50 AM.