Copies image data from the clipboard.
public static RasterImage Paste(
System.IntPtr owner
)
Public Shared Function Paste(
ByVal owner As System.IntPtr
) As RasterImage
public:
static RasterImage^ Paste(
System::IntPtr owner
)
owner
Handle to the active window (use System.Windows.Forms.Control.HandleControl.Handle).
A reference to a new RasterImage object created using the data in the Windows clipboard.
The image on the clipboard must be a DIB, DDB, or a WMF.
The image will contain the same Width, Height, and BitsPerPixel as the image contained in the clipboard.
The Order will be set to RasterByteOrder.Bgr. If the copied image is not in Bgr order, it is up to you to change its color Order using ColorResolutionCommand.
To determine whether a region was pasted, use HasRegion.
using Leadtools;
using Leadtools.Controls;
using Leadtools.Codecs;
using LeadtoolsExamples.Common;
public void RasterClipboard_Paste()
{
if (RasterClipboard.IsReady)
{
/// Copy the bitmap from the clipboard
_imageViewer.Image = RasterClipboard.Paste(_imageViewer.Handle);
MessageBox.Show("Paste is Successful");
}
else
{
MessageBox.Show("Paste Failed");
}
}
Imports Leadtools
Imports Leadtools.Controls
Imports Leadtools.Codecs
Imports LeadtoolsControlsExamples.LeadtoolsExamples.Common
Public Sub RasterClipboard_Paste(ByVal imageViewer As ImageViewer)
If RasterClipboard.IsReady Then
''' Copy the bitmap from the clipboard
imageViewer.Image = RasterClipboard.Paste(imageViewer.Handle)
MessageBox.Show("Paste is Successful")
Else
MessageBox.Show("Paste Failed")
End If
End Sub
Products |
Support |
Feedback: Paste Method (RasterClipboard) - Leadtools.Controls |
Introduction |
Help Version 19.0.2017.6.20
|
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET
Your email has been sent to support! Someone should be in touch! If your matter is urgent please come back into chat.
Chat Hours:
Monday - Friday, 8:30am to 6pm ET
Thank you for your feedback!
Please fill out the form again to start a new chat.
All agents are currently offline.
Chat Hours:
Monday - Friday
8:30AM - 6PM EST
To contact us please fill out this form and we will contact you via email.