60001445 Is it possible to choose the clipboard formats in cmdClipCopy, cmdClipPaste

Article 60001445
Type Wish
Product Engine
Version 6020
Date Added 7/8/2011 12:00:00 AM
Fixed (7/11/2011 12:00:00 AM)
Submitted by Tchouakeu Fongue

Summary

Is it possible to choose the clipboard formats in cmdClipCopy, cmdClipPaste

Solution

A new property ClipboardFormat of vdDocument.FileProperties was added in 6021.

It specifies the clipboard data used from the vdCommandAction.CmdClipCopy and vdCommandAction.CmdClipCut commands

It gets one or more of the following values.

 

1. ClipboardFormats.DocumentStream 

       Clipboard data contains a byte array that represents a vdDocument produced by vdSelection.ToDocument method.

      The System.Windows.Forms.Clipboard.GetData(vdDocument.ClipboardVDMLBytesFormat) can be used to access data

2. ClipboardFormats.Image   

      Clipboard data contains an Image. The System.Windows.Forms.Clipboard.GetImage can be used to access data

3.  ClipboardFormats.FileDrop

     Clipboard data contains an collection of one string that represents an existing file on disk.

     The System.Windows.Forms.Clipboard.GetFileDropList can be used to access data

     

Default Value for ClipboardFormat property of vdDocument.FileProperties  is all the above values together.

In case that you are using .NET enviroment in Debug mode you might get Visual Studio freezes whne call the CmdClipCopy or CmdClipPaste.

In this case use the document.FileProperties.ClipboardFormat = ClipboardFormats.DocumentStream  + ClipboardFormats.Image (without ClipboardFormats.FileDrop)

Send comments on this topic.