ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Subtotal row formula (https://www.excelbanter.com/excel-programming/421627-subtotal-row-formula.html)

MikeF[_2_]

Subtotal row formula
 

Need the following formula to hit the 10th column over [column N at present,
ie offset(0,10) ] for each subtotal row in d2.d500 - of which presently three
rows come up, but there could be more or less rows depending on the content
....
ActiveCell.Formula = ActiveCell.Formula & "/2"

*** The tricky part [for me anyway!] is that it cannot apply to the Grand
Total row, whose text also comes up in column d.

This one's a bit out there, thanx for any ideas.

Regards,
- Mike




Mike

Subtotal row formula
 
I could help if you would like to send me a copy of the workbook.

"MikeF" wrote:


Need the following formula to hit the 10th column over [column N at present,
ie offset(0,10) ] for each subtotal row in d2.d500 - of which presently three
rows come up, but there could be more or less rows depending on the content
...
ActiveCell.Formula = ActiveCell.Formula & "/2"

*** The tricky part [for me anyway!] is that it cannot apply to the Grand
Total row, whose text also comes up in column d.

This one's a bit out there, thanx for any ideas.

Regards,
- Mike




MikeF[_2_]

Subtotal row formula
 
Don't mind sending it, but I MADE A MISTAKE in the original post.
The Grand Total DOES need to be included.
So *everything* in range d2.d500 that contains the string Total --- the 10th
column over needs to have the formula ....
ActiveCell.Formula = ActiveCell.Formula & "/2"

Believe that makes thing easier ..!

Sincerely,
- Mike



"Mike" wrote:

I could help if you would like to send me a copy of the workbook.

"MikeF" wrote:


Need the following formula to hit the 10th column over [column N at present,
ie offset(0,10) ] for each subtotal row in d2.d500 - of which presently three
rows come up, but there could be more or less rows depending on the content
...
ActiveCell.Formula = ActiveCell.Formula & "/2"

*** The tricky part [for me anyway!] is that it cannot apply to the Grand
Total row, whose text also comes up in column d.

This one's a bit out there, thanx for any ideas.

Regards,
- Mike




Mike

Subtotal row formula
 
send to
Show what the workbook looks like before the macro will run and what you
want it to look like after it runs

"MikeF" wrote:

Don't mind sending it, but I MADE A MISTAKE in the original post.
The Grand Total DOES need to be included.
So *everything* in range d2.d500 that contains the string Total --- the 10th
column over needs to have the formula ....
ActiveCell.Formula = ActiveCell.Formula & "/2"

Believe that makes thing easier ..!

Sincerely,
- Mike



"Mike" wrote:

I could help if you would like to send me a copy of the workbook.

"MikeF" wrote:


Need the following formula to hit the 10th column over [column N at present,
ie offset(0,10) ] for each subtotal row in d2.d500 - of which presently three
rows come up, but there could be more or less rows depending on the content
...
ActiveCell.Formula = ActiveCell.Formula & "/2"

*** The tricky part [for me anyway!] is that it cannot apply to the Grand
Total row, whose text also comes up in column d.

This one's a bit out there, thanx for any ideas.

Regards,
- Mike





All times are GMT +1. The time now is 02:16 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com