# HideReadOnly
{: .no_toc }

Returns or sets whether the Open dialog hides its read-only choice.

Syntax: *object*.**HideReadOnly** [ = *boolean* ]

*object*
: *required* An object expression that evaluates to a **cDialog**.

*boolean*
: A **Boolean**. **True** sets `OFN_HIDEREADONLY`. The default is **True**.

## Remarks

[**ShowOpen**](/tB/Packages/Contributed/TBMANLIB_Dialog/cDialog/ShowOpen.md) and [**ShowSave**](/tB/Packages/Contributed/TBMANLIB_Dialog/cDialog/ShowSave.md) both pass the flag, and Windows describes it as hiding the Read Only check box. [**ShowBrowseForFolder**](/tB/Packages/Contributed/TBMANLIB_Dialog/cDialog/ShowBrowseForFolder.md) ignores it.

The Open dialog that Windows shows has no Read Only check box. With **HideReadOnly** **False**, its *Open* button is a split button whose menu holds *Open* and *Open as read-only*. With the default **True**, it is a plain button. The class does not read the flags back from the dialog, so the choice that the user made is not reported.

## Example

```tb check_build check_run
Dim dlg As New cDialog
Debug.Print dlg.HideReadOnly   ' True

dlg.HideReadOnly = False
Debug.Print dlg.HideReadOnly   ' False
```

This example shows the Open dialog with the *Open as read-only* choice.

```tb check_build
Dim dlg As New cDialog
dlg.HideReadOnly = False
Debug.Print dlg.ShowOpen()
```

## See Also

- [ReadOnly](/tB/Packages/Contributed/TBMANLIB_Dialog/cDialog/ReadOnly.md) property -- sets the read-only flag of the Open dialog
- [ShowOpen](/tB/Packages/Contributed/TBMANLIB_Dialog/cDialog/ShowOpen.md) method -- shows the Open dialog
- [cDialog](/tB/Packages/Contributed/TBMANLIB_Dialog/cDialog/index.md) class -- overview
