Ocx memoryleak?

RilRil Member Posts: 6
edited 2003-10-03 in Navision Attain
Hi
I did expect that an OCX would "die" when the calling navision object is terminated. But looking at the taskmanager it seems that the FIN.exe keeps growing - i have no evidence that it is true.
How do you programmatically insure that an ocx is terminated within the navsion object?
Richard Lindberg

Comments

  • LG_HellströmLG_Hellström Member Posts: 13
    Not sure you can.. ocxVariable.Close() (or .Clear or whatever) should do the trick, but if it isn't I guess you're up to a leak..

    Had the similiar with SyBase Provider using ADO automation to replicate data with their SQL, that client grew to some 104MB usage until it dropped dead..

    Not much to do IMO.
    Did I commit today?
  • janpieterjanpieter Member Posts: 298
    Hi,

    Your conclusion that the OCX isn't getting terminated is right, but it isn't caused by the OCX.

    When using CLEAR in C/AL the OCX should be removed from memory but it doesn't (at least not in all cases, don't know if it happens in 370).

    I'm an OCX programmer and i noticed that after clearing an OCX I couldn't delete the OCX file.

    The OCX is released only after you exit navision.

    Other then that I didn't notice anything else going wrong, so i don't think it is a problem except that i have to close navision and only then i will be able to recompile my OCX.
    In a world without Borders or Fences, who needs Windows and Gates?
Sign In or Register to comment.