Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Suite Pro
  New Posts New Posts RSS Feed - Getting IDataObject interface from DataObject?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Getting IDataObject interface from DataObject?

 Post Reply Post Reply
Author
Message
DaveH View Drop Down
Newbie
Newbie


Joined: 22 December 2008
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote DaveH Quote  Post ReplyReply Direct Link To This Post Topic: Getting IDataObject interface from DataObject?
    Posted: 22 December 2008 at 11:10pm
In VB6, the event signature for the XtremeSuiteControls' OLEDragDrop event is something like:

Private Sub ListView1_OLEDragDrop(ByVal Data As XtremeSuiteControls.DataObject, Effect As Long, ByVal Button As Integer, ByVal Shift As Integer, ByVal x As Single, ByVal y As Single)

The XtremeSuiteControls.DataObject looks the same as the standard VBRun.DataObject—unfortunately, that interface is rather limited compared to the OLE IDataObject interface. Specifically, it's not possible to specify the FORMATETC.lindex parameter that's needed to handle drag and drop of files from the shell (FileGroupDescriptor and FileContents).

As mentioned in http://www.mvps.org/emorcillo/en/code/vb6/getidataobject.shtml, there's a hack to get an IDataObject from a VBRun.DataObject, and no hack is needed to get one from the VB Common Controls (e.g., MSComctlLib.ListView)—MSComctlLib.DataObject implements the IDataObject interface, so you can simply assign it to an IDataObject variable. Is there some way to do the same for XtremeSuiteControls.DataObject? Assigning it to an IDataObject variable gives a Type mismatch error, and the hack that works for VBRun.DataObject crashes the app (not surprising).
SuitePro version 16.3.1

David Huang
Alterity, Inc.

Inventory and Distribution Management for QuickBooks
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 23 December 2008 at 2:02am
Hi,
Thanks, we will add support of IDataObject cast too.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
jpcoffeyXXX View Drop Down
Groupie
Groupie


Joined: 16 August 2005
Location: United States
Status: Offline
Points: 31
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpcoffeyXXX Quote  Post ReplyReply Direct Link To This Post Posted: 15 March 2009 at 4:41pm

"Thanks, we will add support of IDataObject cast too."


Oleg, David Huang's suggestion is quite valuable as I have been looking for this functionality as well.  Were you able to get this completed for CodeJock Suite Pro 2009?  Thank you for your feedback.

Sincerely,

John P. Coffey
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.186 seconds.