# CreatePreview(VisualElement)

> Implement this method to make a custom UIElements inspector preview.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor](/engine/6000.5/script-reference/unityeditor.md)
* **Assembly:** UnityEditor.CoreModule

```csharp
public virtual VisualElement CreatePreview(VisualElement inspectorPreviewWindow)
```

### Parameters

**** (\[VisualElement]\(/engine/6000.5/script-reference/unityengine/uielements/visualelement)):&#x20;

### Returns

| Type                                                                                     | Description |
| ---------------------------------------------------------------------------------------- | ----------- |
| [VisualElement](/engine/6000.5/script-reference/unityengine/uielements/visualelement.md) |             |

### Remarks

Inside this method, you can create your own custom UIElements inspector preview for a specific object type.

**Note:** This function has to be overridden in order to work.
