LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 54
Default INT to ROUNDUP

Hello all, I would like some assistance.
Using Excel 2007 on Vista
Confused with RoudUp and Round in procedure
Some thing to do with remainder didgets. How do I name them as long or
whatever

Public Sub CashFlow()
Const dCashCommission As Double = 0.05
Const dCashTake As Double = 0.2
Const dCashInvest As Double = 0.6
Dim dDistribute(1 To 4) As double
Dim i As Long
dAmount = ActiveCell.Value
'This next line in the macro I would like to change to:-
dDistribute(1) = RoundUp(dAmount * dCashCommission,2)

'change from Int to RoundUp? Works with Int, can't get it to work with
RoundUp

dDistribute(1) = Int(dAmount * dCashCommission)
dDistribute(2) = Int(dAmount * dCashTake)
dDistribute(3) = Int(dAmount * dCashInvest)
dDistribute(4) = dAmount - dDistribute(1) - dDistribute(2) -
dDistribute(3)
With Range("T1:T4")
For i = 1 To 4
.cells(i).Value = .cells(i).Value + dDistribute(i)
Next i
End With
ActiveCell.Offset(1, -14).Range("A1").Select
End Sub

Any help welcome and thanks.
Skinman

 
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
can't roundup sum swell estimator Excel Worksheet Functions 3 September 4th 08 03:48 AM
RoundUP juanpablo Excel Discussion (Misc queries) 11 July 9th 08 11:11 PM
Roundup in VBA Jeff Excel Discussion (Misc queries) 3 June 3rd 08 08:59 PM
how to use roundup r4319hb Excel Discussion (Misc queries) 2 December 24th 05 01:27 PM
Trying To Roundup only if more than zero G33kman Excel Discussion (Misc queries) 2 November 29th 05 08:26 PM


All times are GMT +1. The time now is 02:32 PM.

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"