Declare Function OleCreatePictureIndirect
03.01.2020 12:31:11
feuerharry
Mein Programm läuft auf Office 2010 32Bit einwandfrei, aber auf 64Bit bleibt es bei Declare Function OleCreatePictureIndirect in der vorletzen Zeile stecken.
Meine Frage:
Gibt es eine Anwendung, wo das Programm auf beiden Versionen läuft (32 +64Bit), wenn ja wo muss ich das einfügen?
Muss ich für beide Versionen verwenden !!!
Habe alle Private Declare Function geändert auf Private Declare PtrSafe Function.
https://www.herber.de/bbs/user/134112.xlsm
***************************************************************************
Private Function Create_Picture( _
ByVal plnghPic As Long) As IPictureDisp
Dim udtPicInfo As PIC_DESC, udtID_IDispatch As GUID
Dim objPicture As IPictureDisp
With udtID_IDispatch
.Data1 = &H20400
.Data4(0) = &HC0
.Data4(7) = &H46
End With
With udtPicInfo
.lngSize = Len(udtPicInfo)
.lngType = PICTYPE_BITMAP
.lnghPic = plnghPic
.lnghPal = 0
End With
Call OleCreatePictureIndirect(udtPicInfo, udtID_IDispatch, 0&, objPicture) '**bleibt hier _
Stecken
Set Create_Picture = objPicture
End Function
************************************************************************
MFG feuerharry