You must make sure any connections created are disconnected, C5 will happend for sure if you leave even one connection before your object destroys.
Make sure you keep track of any connection you've created and disconnet any remaining connections in you destroy event.
>I used to get this error but not always:
>
>Erreur irrécupérable : Code d'exception=C0000005 @ 2002/02/01 10:13:37. Fichier journal d'erreurs : D:\Kitchantier\Kitchantier\Exe\VFP7Rerr.log
> Appelé à partir de rap_cac line 1172 {D:\Kitchantier\Kitchantier\Exe\progs\rapports.prg rapports.fxp}
> Appelé à partir de ON... line 0 { }
> Appelé à partir de main line 79 {D:\Kitchantier\Kitchantier\Exe\progs\main.prg d:\kitchantier\kitchantier\exe\kitchantier.exe}
>
>This is my code:
>LOCAL lcQUERY
> lcQUERY = "SELECT COM_CODE COMMANDE," ;
> +"COM_INTITULE INTITULE ....." Approx. : 2700chars long.
>
>lnHANDLE = SQLCONNECT("ODBC_CONNECTION")
>IF lnHANDLE<=0 .OR. SQLEXEC(lnHANDLE, lcQUERY, "CUR_TEMP")<=0
> SQLDISCONNECT(lnHANDLE)
>ENDIF
>
>
>The C000005 error is always on the SQLEXEC() function.
>
>Why?
>
>Thanks a lot
Previous
Next
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