Exit Error : 13.04 OLE

Exit Error : 13.04 OLE

Postby TimStone » Fri May 17, 2013 4:04 pm

When I moved to 13.04 ( from a 12.11 version ), on my MSVC builds I started getting an error when exiting the application.

Now I also get it when exiting my longstanding builds with xHarbour ( commercial ).

The error occurs when exiting the main application, IF an OLE instance has been used at some point.

The exact error is: Destructors Disabled : Destructor of class 'TOLEAUTO' can't be executed

I'd sure like to get around this ! Thanks for input.

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2945
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Exit Error : 13.04 OLE

Postby Antonio Linares » Fri May 17, 2013 4:47 pm

Tim,

Whereever you use an OLE object, when you are done with you must do:

oMyOleObject := nil

thats all :-)
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42120
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Exit Error : 13.04 OLE

Postby TimStone » Fri May 17, 2013 5:09 pm

OK ... this relates to the Codejock calendar opened within my main program.

If I open the calendar ( MDI window ), then close it, all appears to be fine. However, when I then exit the main program, that error appears.

If I don't open the calendar, and exit the main program, no error appears. Thus, we can conclude the calendar class is the cause of the problem.

There are two ActiveX components created in the program, ::ocalex and ::oDtPick.

In the End( ) method which is called when I exit the calendar, I now have:

::oCalex := nil
::oDtPick := nil

It still gets the error message.

Thanks for thinking about a solution to this.

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2945
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Exit Error : 13.04 OLE

Postby Richard Chidiak » Fri May 17, 2013 5:51 pm

Antonio

Is this related to 13.04 ?

Richard
http://www.cbati.com

Uestudio
Fwh 13.05 Harbour 3.2 MSVC 2013
User avatar
Richard Chidiak
 
Posts: 946
Joined: Thu Oct 06, 2005 7:05 pm
Location: France

Re: Exit Error : 13.04 OLE

Postby Antonio Linares » Fri May 17, 2013 6:04 pm

Richard,

No, not at all. This is related to Harbour OLE management.

Tim,

Please, in those places where you have created an ActiveX please do (at the end):

oActiveX:oOleAuto := nil

if this solves it, then we need to implement an End() method for Class TActiveX
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42120
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Exit Error : 13.04 OLE

Postby Richard Chidiak » Fri May 17, 2013 6:11 pm

Antonio

That's good news, i thought something was different with 13.04 , not using this build because of combobox , i have plenty of these.

I do not end the codejock objects and it works OK BUT i end the window in a different way than Tim

I will send to Tim a copy of my program to see if it helps, and i promised you a sample of codejock with Harbour, i will find some time this week end to have it ready,

Regards

Richard
http://www.cbati.com

Uestudio
Fwh 13.05 Harbour 3.2 MSVC 2013
User avatar
Richard Chidiak
 
Posts: 946
Joined: Thu Oct 06, 2005 7:05 pm
Location: France

Re: Exit Error : 13.04 OLE

Postby Antonio Linares » Fri May 17, 2013 6:34 pm

Richard,

I have published a revised combobox.prg that was working fine in my tests:
viewtopic.php?p=144816#p144816

though I have just seen that Lucas reported a new bug (after the changes):
viewtopic.php?p=144983#p144983
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42120
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Exit Error : 13.04 OLE

Postby TimStone » Fri May 17, 2013 6:44 pm

Antonio,

Could you publish an update 13.04 for download once you resolve the combobox ?

Thanks.

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2945
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Exit Error : 13.04 OLE

Postby TimStone » Fri May 17, 2013 6:57 pm

METHOD End() CLASS MpCal

oCalex:oOleAuto := nil
oDtPick:oOleAuto := nil

RETURN .t.

Does not work make a difference. Am I not understanding what you want me to do ?
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2945
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Exit Error : 13.04 OLE

Postby Antonio Linares » Fri May 17, 2013 7:12 pm

Tim,

I have just published some minor changes to combobox.prg, here my tests are fine. Once its is confirmed as ok then we will published a revised 13.04 :-)

Your code is fine, thats what I meant, anyhow please place a MsgInfo() there to be sure it is called:

METHOD End() CLASS MpCal

MsgInfo( "end" )
oCalex:oOleAuto := nil
oDtPick:oOleAuto := nil

RETURN .t.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42120
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Exit Error : 13.04 OLE

Postby lucasdebeltran » Fri May 17, 2013 7:14 pm

Antonio,

Remember also it is pending the bug at xBrowse:
viewtopic.php?f=3&t=26244

Thank you.
Muchas gracias. Many thanks.

Un saludo, Best regards,

Harbour 3.2.0dev, Borland C++ 5.82 y FWH 13.06 [producción]

Implementando MSVC 2010, FWH64 y ADO.

Abandonando uso xHarbour y SQLRDD.
User avatar
lucasdebeltran
 
Posts: 1303
Joined: Tue Jul 21, 2009 8:12 am

Re: Exit Error : 13.04 OLE

Postby TimStone » Fri May 17, 2013 7:51 pm

OK ... had a problem because it was linking in the wrong library, but now I'm getting the correct one and still have the problem.

Here are the two object creations:

::oCalex := tActiveX():New( ::oPanelCalex, "Codejock.CalendarControl.15.0.1" )
::oDtPick := tActiveX():New( ::oPanelExplorer,"Codejock.DatePicker.15.0.1" )

Here is the end method:
METHOD End() CLASS MpCal
oDtPick:oOleAuto := nil
oCalex:oOleAuto := nil
RETURN .t.

This will cause the whole program to abort when I try to close the MDI window with the calendar on it.

IF I change the values to ::oDtPick:oOleAuto, and oCalex:oOleAuto then the window will close, but the same error occurs when I exit the main program.

Yes, with the message info screen in there, the end( ) method is being called.

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2945
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Exit Error : 13.04 OLE

Postby lucasdebeltran » Fri May 17, 2013 8:41 pm

Hello Timm,

If you want, I can test a working simple with MSVC2010.

Just remove your reg code to the product.

Best regards,
Muchas gracias. Many thanks.

Un saludo, Best regards,

Harbour 3.2.0dev, Borland C++ 5.82 y FWH 13.06 [producción]

Implementando MSVC 2010, FWH64 y ADO.

Abandonando uso xHarbour y SQLRDD.
User avatar
lucasdebeltran
 
Posts: 1303
Joined: Tue Jul 21, 2009 8:12 am

Re: Exit Error : 13.04 OLE

Postby Antonio Linares » Fri May 17, 2013 8:45 pm

Tim,

Please try this:

METHOD End() CLASS MpCal

::oDtPick:End()
::oCalex:End()

::oDtPick:oOleAuto := nil
::oCalex:oOleAuto := nil

RETURN .t.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42120
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Exit Error : 13.04 OLE

Postby TimStone » Fri May 17, 2013 8:47 pm

Thank you but the problem exists in my older xHarbour.com and in my MSVC2010 builds. I do have both.

The distributed builds are still in xHarbour.com

The testing builds are with MSVC 2010 and Harbour

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2945
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Next

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 79 guests