TActiveX class using FHW64

Post Reply
bradmaudlin
Posts: 23
Joined: Fri Jan 11, 2008 9:58 pm
Location: St Joe, MO

TActiveX class using FHW64

Post by bradmaudlin »

Hello,

Has anyone used the TActiveX class using Harbour, FWH64 and MSVC 2015?
Do .ocx (ActiveX controls) files need to be 32bit or 64bit specific like .lib files?

The same code compiled using Harbour, FWH32 and BCC582 loads the ActiveX and works fine.
But when I compile using FWH64 it errors out on the ActiveX Statement.

MsgInfo("Start oNetePay ActiveX Control")
oNetePay := TActiveX():NEW(oMainDlg,"DSIEMVX.DsiEMVXCtrl.1",1,1,10,10)

I get to the MsgInfo() line then error out with this -

------------------------------------------------------------------------
Application Internal Error - C:\Projects\cmpos\CMPOS64.exe
Terminated at: 2016-05-19 16:33:34
Unrecoverable error 6005: Exception error:

Exception Code:C0000005 ACCESS_VIOLATION
Exception Address:00007FF65E4AD0BE
RAX:0000000000000000 RBX:0000000000000001 RCX:0000000000000000 RDX:0000000080040154
RSI:0000000000000002 RDI:00007FF65E6780FB RBP:000000000000000A
R8 :000000DD06B0E2D8 R9 :0000000000001802 R10:0000000000000000 R11:000000DD06B0E610
R12:0000000000000000 R13:0000000000000000 R14:0000000000000000 R15:00007FF65E7A3E20
CS:RIP:0033:00007FF65E4AD0BE SS:RSP:002B:000000DD06B0E6D0
DS:002B ES:002B FS:0053 GS:002B
Flags:00010202
Exception Parameters: 0000000000000000 0000000000000000

Called from CREATEACTIVEX(0)
Called from TACTIVEX:NEW(0) in .\source\classes\ACTIVEX.PRG
Called from SECURITYDEVICEINIT(513) in NETEPAY.prg
Called from INITCREDITCARD(758) in CMPOS64.prg
Called from (b)SHOWPOSSCREEN(752) in CMPOS64.prg
Called from TDIALOG:INITIATE(0) in .\source\classes\DIALOG.PRG
Called from TDIALOG:HANDLEEVENT(0) in .\source\classes\DIALOG.PRG
Called from DIALOGBOX(0)
Called from TDIALOG:ACTIVATE(0) in .\source\classes\DIALOG.PRG
Called from SHOWPOSSCREEN(752) in CMPOS64.prg
Called from MAIN(566) in CMPOS64.prg
------------------------------------------------------------------------

Thanks,

Brad Maudlin
User avatar
rhlawek
Posts: 165
Joined: Sun Jul 22, 2012 7:01 pm

Re: TActiveX class using FHW64

Post by rhlawek »

Brad,

I'm using harbour and msvc, 2015 for the purpose of this note but I still use 2013 as well. I use a 3rd party product named VideoReDo TV Suite which is a 32 bit app. I can create and use their object without issue from either a 32 or a 64 bit app. However I don't use the TActiveX() class, I use CreateObject()

oPlayer := CreateObject( "VideoReDo5.Application" )

I did just do a quick test with TActiveX() in the 64 bit app. It does not crash with the run time error you are seeing. It does behave differently than does CreateObject(), just doing a brief review of the TActiveX() source that appears to be more how TActiveX() is implemented and the assumptions my code makes and not a real problem. But it doesn't crash.

Robb
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Re: TActiveX class using FHW64

Post by Antonio Linares »

Brad,

I just tested FWH\samples\video.prg which I guess its similar to your code: the ActiveX is created from the dialog ON INIT clause

Here it is working fine in both 32 and 64 bits

To test it, please remember to copy fivewin.avi from c:\fwh\avis to c:\fwh\samples folder

Please use the most recent FWH 64 version 16.04
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
richard-service
Posts: 583
Joined: Tue Oct 16, 2007 8:57 am
Location: New Taipei City, Taiwan
Contact:

Re: TActiveX class using FHW64

Post by richard-service »

Hi
I just to test codejock ActiveX work fine with fwh64-1604
Regards,

Richard

Harbour 3.2.0dev (r1904111533)/xHarbour 1.2.3 Intl. (SimpLex) (Build 20180818) => Borland C++ v7.4
xHarbour 0.99.71 (SimpLex) => Borland C++ v5.5
MySQL v5.7 /ADS v12
Harbour 3.2.0dev (r1603181642) => Borland C++ v7.4 64bit
Post Reply