SOLVED

How do I divide by just the whole number and not the formula?

%3CLINGO-SUB%20id%3D%22lingo-sub-1657987%22%20slang%3D%22en-US%22%3EHow%20do%20I%20divide%20by%20just%20the%20whole%20number%20and%20not%20the%20formula%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1657987%22%20slang%3D%22en-US%22%3E%3CP%3EI%20am%20trying%20to%20divide%202%20cells.%26nbsp%3B%20One%20cell%20is%20a%20number%20I%20put%20in%20and%20the%20other%20is%20calculating%20how%20many%20biweeks%20there%20are%20in%20between%20(%3DDATEDIF(A2%2CB2%2C%22d%22)%2F14)%20so%20when%20I%20divide%20the%20number%20I%20wrote%20in%20by%20the%20number%20that%20is%20calculated%20by%20the%20formula%20it%20gives%20me%20the%20wrong%20number.%20What%20am%20I%20doing%20wrong%3F%26nbsp%3B%20If%20I%20divide%20D%20by%20C%2C%20E%20should%20equal%20%241880.46%20but%20it%20is%20not.%26nbsp%3B%20Cell%20C%20is%20the%20one%20that%20has%20the%20above%20formula.%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22excel.PNG%22%20style%3D%22width%3A%20437px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F217777i0FE2D53945F15B5B%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22excel.PNG%22%20alt%3D%22excel.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1657987%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExcel%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EFormulas%20and%20Functions%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1658052%22%20slang%3D%22en-US%22%3ERe%3A%20How%20do%20I%20divide%20by%20just%20the%20whole%20number%20and%20not%20the%20formula%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1658052%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F790534%22%20target%3D%22_blank%22%3E%40Yayi_Chop07%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ESince%20actually%20number%20of%20weeks%20returned%20is%2018.07143%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1659268%22%20slang%3D%22en-US%22%3ERe%3A%20How%20do%20I%20divide%20by%20just%20the%20whole%20number%20and%20not%20the%20formula%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1659268%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F521%22%20target%3D%22_blank%22%3E%40Sergei%20Baklan%3C%2FA%3E%26nbsp%3Bis%20there%20a%20way%20to%20just%20have%20it%20dive%20by%20the%20integer%20and%20not%20the%20number%20with%20decimals%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E
New Contributor

I am trying to divide 2 cells.  One cell is a number I put in and the other is calculating how many biweeks there are in between (=DATEDIF(A2,B2,"d")/14) so when I divide the number I wrote in by the number that is calculated by the formula it gives me the wrong number. What am I doing wrong?  If I divide D by C, E should equal $1880.46 but it is not.  Cell C is the one that has the above formula.excel.PNG

5 Replies

@Yayi_Chop07 

Since actually number of weeks returned is 18.07143

@Sergei Baklan is there a way to just have it dive by the integer and not the number with decimals?

Best Response confirmed by Yayi_Chop07 (New Contributor)
Solution

@Yayi_Chop07 

You may wrap it by ROUND() to round, or use INT() to cut decimals or similar functions - depends on how you'd like to calculate. As example

 =ROUND(DATEDIF(A2,B2,"d")/14,0) 

or more simple variant

 =ROUND( (B2-A2)/14,0) 

@Sergei Baklan  yes!!! You are correct, thank you so much!