PRB: User-defined Formats in OLE Drag-Drop Require Byte Arrays

Last reviewed: April 2, 1997
Article ID: Q163234
The information in this article applies to:
  • Microsoft Visual Basic Enterprise Edition for Windows, version 5.0

SYMPTOMS

When using the SetData method for OLE Drag/Drop functionality, data in a user-defined format will cause the following message to be displayed at run- time:

   "Non-intrinsic OLE drag-and-drop formats used with SetData require
   Byte array data. GetData may return more bytes than were given to
   SetData."

RESOLUTION

To work around this behavior, make sure that the data being dragged is placed into a byte array. Decoding the byte array using the GetData is then dependent upon the methods by which this array was created.

STATUS

This behavior is by design.

MORE INFORMATION

The following formats are known formats when using SetData and GetData:

   Name       Constant
   ---------  ------------
   Text       vbCFText
   Metafile   vbCFMetafile
   DIB        vbCFDIB
   Bitmap     vbCFBitmap
   Palette    vbCFPalette
   Rich Text  vbCFRTF
   DDE Link   vbCFLink
 

	
	


Keywords : kbprg vb5all VBKBAX kbprb
Version : 5.0
Platform : WINDOWS
Issue type : kbprb


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: April 2, 1997
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.