H:V format

afrexico

New Member
Joined
Aug 17, 2011
Messages
2
I wanted to know if there is a way for Excel to present a grade slope as H:V, i.e. 0.25 as 4:1 slope?
 

Excel Facts

Quick Sum
Select a range of cells. The total appears in bottom right of Excel screen. Right-click total to add Max, Min, Count, Average.
How about:

=MID(TEXT(A1," 0/0"),FIND("/",TEXT(A1," 0/0"))+1,999)&":"&TRIM(MID(TEXT(A1," 0/0"),1,FIND("/",TEXT(A1," 0/0"))-1))

assuming the 0.25 is in cell A1.

Or even:
=TRIM(MID(TEXT(A1," ??/??"),FIND("/",TEXT(A1," ??/??"))+1,999))&":"&TRIM(MID(TEXT(A1," ??/??"),1,FIND("/",TEXT(A1," ??/??"))-1))
to cope with a wider range of numbers.
 
Last edited:
Upvote 0
Thank you for your replies. They all work. As far as the last response it did work but with odd decimals it give a very long number XXXXXX:1 result.
 
Upvote 0
If you like the shorter formula, you can reduce the numbers after the decimal to 3 by using =TEXT(1/A1,"####.###")&":1"
 
Upvote 0
Or you could incorporate it into the TEXT function:

=TEXT(1/A1,".0##\:1")
 
Upvote 0

Forum statistics

Threads
1,224,527
Messages
6,179,337
Members
452,907
Latest member
Roland Deschain

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top