Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 08-03-2016, 12:08 PM
gebobs gebobs is offline Round num_digits calculated? Windows 7 64bit Round num_digits calculated? Office 2010 64bit
Expert
Round num_digits calculated?
 
Join Date: Mar 2014
Location: Atlanta
Posts: 837
gebobs has a spectacular aura aboutgebobs has a spectacular aura about
Default Round num_digits calculated?

Is it possible to use a formula within the round function to determine the rounding number of digits?

For this application, a suppliers price for any SKU is dependent on the dimensions which can vary widely thus it's easiest to calculate the price. The problem I have is when calculating a supplier's price, most suppliers use a price with four decimals, one uses three, and another uses two.

Initially, I had this which works fine for all but the two that use fewer digits.

=ROUND([price calculation],4)

I tried making a lookup table with the suppliers and their rounding then vlookup in the formula as follows, but I get a #REF! error.

=ROUND([price calculation],VLOOKUP([@Supplier],Round,2))

I tried using an IF, but I get the same #REF! error.

=ROUND([price calculation],IF([@Supplier]="H",2,4))

Anyone have any bright ideas? I have attached the workbook if you dare.
Attached Files
File Type: xlsx Rounding.xlsx (22.5 KB, 11 views)
Reply With Quote
  #2  
Old 08-03-2016, 03:10 PM
gebobs gebobs is offline Round num_digits calculated? Windows 7 64bit Round num_digits calculated? Office 2010 64bit
Expert
Round num_digits calculated?
 
Join Date: Mar 2014
Location: Atlanta
Posts: 837
gebobs has a spectacular aura aboutgebobs has a spectacular aura about
Default

I got it to work with the Vlookup. I don't know what happened, but I started over from where I took it up today and everything worked swimmingly.

Good work, gebobs. You've done it again, old master. Not exactly sure what the hell you did, but done and done.
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Round num_digits calculated? Data validation the other way round? Officer_Bierschnitt Excel 3 11-13-2015 10:12 PM
Round num_digits calculated? Setting up a round label template obiwan Word 1 11-06-2014 06:55 AM
Text animation to wrap round an object caz46 PowerPoint 0 10-20-2012 08:01 AM
Round num_digits calculated? Round off the number ubns Word VBA 4 09-06-2012 03:55 PM
how can i make round border edges bobafet Word 4 11-19-2009 04:40 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 02:03 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft