# degrees minutes seconds number format code?!!

#### stark

##### New Member
i have a question:
when i import my text file into excel it shows the degrees as 32.245563223 (this is NOT decimal degrees...it is degrees minutes seconds)

i need it to be displayed like this: 32°24'55.6"

what would the number format code be to show this?

thanks,
stark

### Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.

#### stark

##### New Member
thanks...

when i enter the code [hh]°mm'ss\" it turns my latitude from: 31.295530155
to: 751°05'34"

any ideas as to what could be wrong?

thanks again,
stark

#### MPBotti

##### New Member
Hi Stark,

To fix that problem, I prefer to use a custom format as ##° ##' ##.0000\" \S.

Suerte,

#### jkeohane

##### New Member
Alas I have tried this many times, and I have not succeed in simply displaying the number this way. It really should be built into Excel.

I simply put the degrees, minutes, and seconds in different cells. Then I make another cell called something like decimal degrees, and I just add them up and divide by the appropriate factors of 60. If you have a data file, I guess you need to either figure out how to import them separately, or understand what it is doing wrong.

In Stark's example above, you would simply use the MOD() function to separate this into three different cells, and then put them back together again.

#### MARK858

##### MrExcel MVP
Maybe in a separate cell multiply by 10000 and custom format as 0º 00' 00.0''

Book1
AB
132.2455632232º 24' 55.6''
Sheet1
Cell Formulas
RangeFormula
B1B1=A1*10000

Replies
14
Views
144
Replies
1
Views
167
Replies
6
Views
227
Replies
9
Views
215
Replies
3
Views
162