about fractions

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I would like to display a compound fraction, but i only want the whole number
and the numerator of the fraction to be displayed.

For example:
5- 14/30
displayed as: 5- 14

thanks for any help
patrick
 
Hello Patrick,

You must use a formula for this as it can't be done with formatting alone.
You could use something like this ...

=INT(A1)&" - "&(A1-INT(A1))*30

...assuming your number was a valid number and resided in A1, and that you
always wanted it expressed in n/30.

HTH
 
are the numbers always displayed in that format?ie with the dash and the /
=LEFT(A1,SEARCH("-",A1,1)-1)&MID(A1,FIND("-",A1,1),SEARCH("/",A1,1)-SEARCH("-",A1,1))
 
I would like to display a compound fraction, but i only want the whole number
and the numerator of the fraction to be displayed.

For example:
5- 14/30
displayed as: 5- 14

thanks for any help
patrick

The value you display will be a text value. With the original number in H1:

=LEFT(TEXT(H1,"#""- ""??/30"),FIND("/",TEXT(H1,"#""- ""??/30"))-1)


--ron
 
zack, thanks! it worked great! although i ended up needing to round
(A1-INT(A1))*30
for some reason without the round function I would get 5-1.9999999999999
instead of 5-2

but it got me where i needed to be

Thank You
patrick
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top