XL.Book.SetDpiAwareness
-----------------------

Sets the DpiAwareness property.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [XL](component_XL.md) | [16.1](newinversion161.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "XL.Book.SetDpiAwareness"; BookRef; Value ) 

**MBS**( **"XL.Book.SetDpiAwareness";** /\* Sets the DpiAwareness property. \*/  
**$BookRef**; /\* The reference to the workbook. Please use [XL.LoadBook](XLLoadBook.md) to load a file.e.g. $ref \*/   
**$Value**) /\* The new value.  
Pass 1 to enable or 0 to disable. \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| BookRef | The reference to the workbook. Please use [XL.LoadBook](XLLoadBook.md) to load a file. | $ref |
| Value | The new value.   Pass 1 to enable or 0 to disable. |  |

### Result

Returns OK or error.

### Description

Sets the DpiAwareness property.  
### See also

- [XL.Book.GetDpiAwareness](XLBookGetDpiAwareness.md)
- [XL.LoadBook](XLLoadBook.md)

### Release notes

- **Version Prerelease**
    - Added XL.Book.GetDpiAwareness and XL.Book.SetDpiAwareness functions.

Created 20th January 2026 , last changed 20th January 2026

  
[XL.Book.SetDefaultFont](XLBookSetDefaultFont.md) - [XL.Book.SetRGBMode](XLBookSetRGBMode.md)

[HTML Version](XLBookSetDpiAwareness.shtml)