---
title: "Bitmap..::.LoadFromHdc Method "
canonical: https://www.graphicsmill.com/docs/gm5/M_Aurigma_GraphicsMill_Bitmap_LoadFromHdc_2_cd97b51f.htm
product: "Graphics Mill 5.5 for .NET"
---

This documentation is for the old version. [Go to the latest Graphics Mill docs](https://www.graphicsmill.com/docs/gm/)

# Bitmap.LoadFromHdc Method 
 
Captures a bitmap from the specified device context.
 
**Namespace:** [Aurigma.GraphicsMill](https://www.graphicsmill.com/docs/gm5/N_Aurigma_GraphicsMill.htm.md)
 **Assembly:** Aurigma.GraphicsMill (in Aurigma.GraphicsMill.dll)
 
## Syntax
  
```
Public Sub LoadFromHdc ( _hdc As IntPtr, _rectangle As Rectangle _
)
```
 
```csharp
public void LoadFromHdc(IntPtr hdc,Rectangle rectangle
)
```
 
### Parameters
 
 - hdc
     - Type: [System.IntPtr](http://msdn2.microsoft.com/en-us/5he14kz8)
The handle to device context to grab the bitmap from.

 - rectangle
     - Type: [System.Drawing.Rectangle](http://msdn2.microsoft.com/en-us/1zk39146)
The rectangle on the window associated with this device context to grab from.
   
## See Also

### Reference

- [Bitmap Class](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Bitmap.htm.md)
- [Aurigma.GraphicsMill Namespace](https://www.graphicsmill.com/docs/gm5/N_Aurigma_GraphicsMill.htm.md)
