Table of Contents

Method DeleteDC

Namespace
Alternet.UI
Assembly
Alternet.UI.Common.dll

DeleteDC(nint)

Deletes the specified device context (DC).

public static extern bool DeleteDC(nint hdc)

Parameters

hdc nint

A handle to the device context to be deleted.

Returns

bool

true if the device context is successfully deleted; otherwise, false.

Remarks

This method is a wrapper for the native DeleteDC function in the GDI library. It should be used to release a device context that was created using functions such as CreateCompatibleDC. Failure to delete a device context may result in resource leaks.