Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
penri0_0
 
Posts: n/a
Default Round function in If statement


Hello,

Hopefully a nice simple one for you all to improve your post count! ;)


In this formula
=IF(ISERROR(F21/C21)=TRUE,0,(F21/C21))

where can i insert the Round function to 2 places (i.e. it rounds up or
down with no decimal places)

I can't figure it out.

thanks in advance


--
penri0_0


------------------------------------------------------------------------
penri0_0's Profile: http://www.excelforum.com/member.php...o&userid=28947
View this thread: http://www.excelforum.com/showthread...hreadid=545427

  #2   Report Post  
Posted to microsoft.public.excel.misc
Pete_UK
 
Posts: n/a
Default Round function in If statement

Try this:

=IF(ISERROR(F21/C21),0,round(F21/C21,2))
or a slight variation:
=IF(C21=0,0,round(F21/C21,2))

You will also have to format the cell as a number with 2 decimal places
to see them - sounds like your current format is 0 dp.

Hope this helps.

Pete

  #3   Report Post  
Posted to microsoft.public.excel.misc
penri0_0
 
Posts: n/a
Default Round function in If statement


Thanks Pete, works perfectly.


--
penri0_0


------------------------------------------------------------------------
penri0_0's Profile: http://www.excelforum.com/member.php...o&userid=28947
View this thread: http://www.excelforum.com/showthread...hreadid=545427

  #4   Report Post  
Posted to microsoft.public.excel.misc
Pete_UK
 
Posts: n/a
Default Round function in If statement

Thanks for the feedback.

Pete

Reply
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
how do i set up round function run superman Excel Worksheet Functions 1 October 6th 05 08:13 PM
Change a number to round up without a function teebee0831 Excel Discussion (Misc queries) 7 June 30th 05 05:55 PM
Formatting a cell with a function (IF statement) Dreaming Excel Worksheet Functions 2 June 30th 05 02:12 AM
Automatically up date time in a cell Mark Excel Discussion (Misc queries) 5 May 12th 05 12:26 AM
clock Wildman Excel Worksheet Functions 2 April 26th 05 10:31 AM


All times are GMT +1. The time now is 03:38 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"