Rounding macro from two decimals place to nearest whole number then auto sum to last data row

RAM1972

Board Regular
Joined
Jun 29, 2014
Messages
217
Hi All

I have a big spreadsheet where a macro copies from working sheet to a report sheet in same workbook.

Am looking macro to round still to last data row and then autosum with bold red

Looking macro for header round which should look in header Amount to round to whole number

Actually the headers are found column E and F , but however sometimes may be modulable as data changes according working spreadsheet e.g amount and round headers may be found at column H and G or X and Y .

Can anyone help
Thanks

Code:
 [TABLE]
<colgroup><col style="mso-width-source:userset;mso-width-alt:2486;width:51pt" width="68">  <col style="mso-width-source:userset;mso-width-alt:4169;width:86pt" width="114">  </colgroup><tbody>[TR]
   [TD="class: xl64, width: 68"][B][COLOR=#00ff00]Amount
[/COLOR][/B][/TD]
   [TD="class: xl65, width: 114"][B][COLOR=#00ff00]Round[/COLOR][/B][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]6847.08[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]6847[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]3308.68[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]3309[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]106.4[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]106[/COLOR]
[/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]252.3[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]252[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]100.32[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]100[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]246.42[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]246[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]40.8[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]41[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]18.2[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]18[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]26.76[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]27[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]10.4[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]10[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]11.4[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]11[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]273.6[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]274[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]3.4[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]3[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]8.4[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]8[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]53.76[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]54[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]19.62[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]20[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="align: right"][COLOR=#0000cd]111.84[/COLOR][/TD]
   [TD="align: right"][COLOR=#0000cd]112[/COLOR][/TD]
  [/TR]
  [TR]
   [TD="class: xl63, align: right"][COLOR=#ff0000]11439.38
[/COLOR][/TD]
   [TD="class: xl63, align: right"][COLOR=#ff0000]11438  [/COLOR]
[/TD]
  [/TR]
 </tbody>[/TABLE]
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"

Forum statistics

Threads
1,215,219
Messages
6,123,684
Members
449,116
Latest member
HypnoFant

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top