Prod.: Engine, ver.: 6020, ID: 60001445, Wish : Is it possible to choose the clipboard formats in cmdClipCopy, cmdClipPaste

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

Article60001445
TypeWish
ProductEngine
Version6020
Date Added7/8/2011
FixedYes [7/11/2011]
Submitted byTchouakeu Fongue
Keywords

Subject

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

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)