|
|||
|
Hi,
my app ist drag'n'drop enabled. If I drop a file from an explorer window, my app imports this file. If I drag'n'drop an outlook 2010 message to an explorer window, it generates a *.msg file in the directory. But: If I try to drag'n'drop an outlook message from outlook to my VO app, the 'unallowed'-sign is shown and I can't import it. How can I import an outlook message directly to my VO app? Ciao Frank I found this post, but there is no answer: http://groups.google.com/group/comp....489e0f520b0ab0 |
|
|
||||
|
||||
|
|
|
|||
|
Frank.
So what are you going to do with it? And secondly, do you understand the nature of the data being dragged? Drag and drop works because the client and the server understand the contents. The contents is either a pointer or data but either way, you need to know how to deconstruct the contents. This is exactly the same as using the clip board. You have to know what's inside. Do you? Geoff "Frank Leverenz" <frank.leverenz@micodat.com> wrote in message news:c653716c-f7d6-4fee-a79a-a4042e4f76b9@d7g2000vbv.googlegroups.com: > Hi, > > my app ist drag'n'drop enabled. If I drop a file from an explorer > window, my app imports this file. > > If I drag'n'drop an outlook 2010 message to an explorer window, it > generates a *.msg file in the directory. > > But: > If I try to drag'n'drop an outlook message from outlook to my VO app, > the 'unallowed'-sign is shown and I can't import it. > > How can I import an outlook message directly to my VO app? > > > Ciao > Frank > > I found this post, but there is no answer: > http://groups.google.com/group/comp....489e0f520b0ab0 |
|
|||
|
Frank,
> If I try to drag'n'drop an outlook message from outlook to my VO app, > the 'unallowed'-sign is shown and I can't import it. > > How can I import an outlook message directly to my VO app? itīs quite easy to visualize the ole drag/drop operation, but i doubt itīs that easy to get access to the underlying dropped Outlook data ( ptr in oOLEDragEvent ataObject ) . To get the required infos you have toimplement - IMO - "IDataObject". http://msdn.microsoft.com/en-us/libr...(v=vs.85).aspx. You should also take a look at "OLEObject:CreateFromOLEDragEvent()" mentioned in the VO-Help, and play around with the OleObject properties. ------------------------ 1. enable OleDragDrop ------------------------ oWin:EnableOLEDropTarget(TRUE) ---------------------------------------------- 2. Implement the "OLEDragOver" - Handler ---------------------------------------------- METHOD OLEDragOver(oOLEDragEvent) CLASS yourWindow LOCAL oPoint AS Point LOCAL lRet AS LOGIC IF oOLEDragEvent:ObjectName == "Outlook" oOLEDragEvent:effect := DROPEFFECT_COPY oPoint := oOLEDragEvent:Position // Ist the mouse within the boundaries of the DropTarget -Control ? IF Between ( oPoint:x , oCtrlDropTarget:Origin:x ,oCtrlDropTarget:Origin:x +oCtrlDropTarget:Size:width ) .AND. ; Between ( oPoint:y , oCtrlDropTarget:Origin:y ,oCtrlDropTarget:Origin:y +oCtrlDropTarget:Size:Height ) lRet := TRUE ENDIF ENDIF // TRUE = "Copy"-Mousepointer will be shown // FALSE = "No-Drop"-Mousepointer will be shown RETURN lRet ---------------------------------------------- 3. Implement the "OLEDrop" - Handler ---------------------------------------------- METHOD OLEDrop(oOLEDragEvent) CLASS YourWindow IF oOLEDragEvent:ObjectName == "Outlook" MessageBox ( 0 , String2Psz ( "Dropped" ) , NULL , 0 ) ENDIF -------------- regards Karl-Heinz |
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|