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: 12
Default Macro Ceiling & Floor Calculation Problem...

Hello,

The following macro calculations are not acting as I expect them to for a
select group of numbers:

fullRange = finishRange - startRange
actName = Application.Ceiling(fullRange / 3, 1)
diffName = (fullRange - actName) / 2
ceilName = Application.Ceiling(diffName, 1)
floorName = Application.Floor(diffName, 1)

Given fullRange = 2 then actName = 1, but diffName = 0, ceilName = 0, &
floorName = 0
Shouldn't diffName = .5, ceilName = 1, and floorName = 0?

Similarly, Given fullRange = 5 then actName = 2, but diffName = 2, ceilName
= 2, & floorName = 2
Shouldn't diffName = 1.5, ceilName = 2, and floorName = 1?

From 1 to 10, the other numbers appear to function correctly. There might
be even others where this doesn't work, but I haven't checked yet.

Thanks much for any help.

Kevin

 
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
Ceiling problem. puiuluipui Excel Discussion (Misc queries) 4 April 6th 09 04:10 PM
Will FLOOR & CEILING work with variable stratifications? johnu Excel Worksheet Functions 1 March 26th 08 06:53 AM
Something like CEILING or FLOOR gusvenables Excel Worksheet Functions 3 October 28th 05 04:09 AM
ceiling & floor Bill Ridgeway New Users to Excel 1 August 7th 05 02:32 PM
EXCEL: FLOOR/SPACE RATIO CALCULATION ANDREW A Excel Worksheet Functions 1 June 21st 05 02:21 PM


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

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"