General information
Category:
COM/DCOM and OLE Automation
Hi All,
i have a problem know, because i want to use the nice OLE drag&drop function in vfp6.0
i have to get an OLE data from Outlook Express 5.0. if i drag a simple mail (without attachment), it is working, but if i try to drag an e-mail which has an attachment i got an error. the lxData is .F., but the clipboardformats is "CF_TEXT", so as i understand the help the lxData should be text as well.
pls. help me!
here is a code what i use in a picture control OLEDragDrop event
LPARAMETERS oDataObject, nEffect, nButton, nShift, nXCoord, nYCoord
LOCAL ARRAY laOLEContents(1)
LOCAL i, nElements, lnIndex, j, lxData
nElements = alen(Thisform.ClipboardFormats,1)
select oledata
FOR i = 1 to nElements
if oDataObject.GetFormat(Thisform.ClipboardFormats[i, 1])
if Thisform.ClipboardFormats[i, 2] = "CF_FILES" or ;
Thisform.ClipboardFormats[i, 2 ] = "CF_HDROP" or ;
Thisform.ClipboardFormats[i, 2 ] = "CFSTR_OLEVARIANTARRAY"
if oDataObject.GetData(Thisform.ClipboardFormats[i, 1], @laOLEContents)
FOR j = 1 to alen(laOLEContents, 1)
insert into oledata (oletype, oledata) values (Thisform.ClipboardFormats [i, 2], laOLEContents[j])
ENDFOR
endif
else
lxData = oDataObject.GetData(Thisform.ClipboardFormats[i, 1], @laOLEContents)
insert into oledata (oletype, oledata) values (Thisform.ClipboardFormats[i, 2], lxData)
endif
ENDIF
NEXT
Ivan
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only