---
title: HEX2DEC – แปลงฐาน 16 เป็นฐาน 10
url: https://www.thepexcel.com/functions/excel/engineering/hex2dec/
type: function-explainer
program: Excel
syntax: =HEX2DEC(number)
date: 2025-12-02
updated: 2025-12-17
scores:
  popularity: 3
  difficulty: 5
  usefulness: 4
---

# HEX2DEC – แปลงฐาน 16 เป็นฐาน 10

> แปลงฐาน 16 เป็นฐาน 10

## คำอธิบาย

แปลงเลขฐานสิบหกเป็นเลขฐานสิบ

## Syntax

```excel
=HEX2DEC(number)
```

## Arguments

| Name | Required | Type | Default | Description |
| --- | --- | --- | --- | --- |
| number | Yes | Text |  | เลขฐานสิบหก |

## ตัวอย่าง

### 1. แปลง 'FF' เป็นฐานสิบ

```excel
=HEX2DEC("FF")
```

**ผลลัพธ์:** `255`

ตัวเลขฐานสิบหก FF เท่ากับ 255 ในฐานสิบ

### 2. แปลงค่าติดลบ

```excel
=HEX2DEC("FFFFFFFFF")
```

**ผลลัพธ์:** `-1`

เลขฐานสิบหก FFFFFFFFF (9 ตัว F) ถือเป็น -1 ใน Excel (สำหรับ 10 บิต)

### 3. ใช้กับรหัสสี

```excel
=HEX2DEC("A0")
```

**ผลลัพธ์:** `160`

แปลงค่าสีในระบบ Hex เป็น Decimal (เช่น สีเขียว A0)

## ฟังก์ชันที่เกี่ยวข้อง

- [BASE – แปลงเลขฐาน](https://www.thepexcel.com/functions/excel/math-and-trigonometry/base/)
- [DEC2HEX – แปลงฐาน 10 เป็นฐาน 16](https://www.thepexcel.com/functions/excel/engineering/dec2hex/)
- [DECIMAL – แปลงเป็นเลขฐาน 10](https://www.thepexcel.com/functions/excel/math-and-trigonometry/decimal/)
- [HEX2BIN – แปลงฐาน 16 เป็นฐาน 2](https://www.thepexcel.com/functions/excel/engineering/hex2bin/)
- [DEC2OCT – แปลงฐาน 10 เป็นฐาน 8](https://www.thepexcel.com/functions/excel/engineering/dec2oct/)

## แหล่งข้อมูลเพิ่มเติม

- [Official Documentation](https://support.microsoft.com/en-us/office/hex2dec-function-8c8c3155-9f37-45a5-a3ee-ee5379ef106e) _(official)_
- [ExcelJet](https://exceljet.net/excel-functions/excel-hex2dec-function) _(guide)_

---

_Source: [https://www.thepexcel.com/functions/excel/engineering/hex2dec/](https://www.thepexcel.com/functions/excel/engineering/hex2dec/)_
