Welcome, Guest
Username: Password: Remember me
CodeTyphon MS Windows (Win7, Win8.x, Win10 and Win11) OS Development, discussions and problems
  • Page:
  • 1

TOPIC:

Access Violation when close IDE 12 years 8 months ago #1763

  • Maximiliano
  • Maximiliano's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 47
  • Thank you received: 3
After install the new version 2.50, to close the IDE gives message Access Violation when I open my project, or when switching to another or close.
Do not get this error if I create a new blank project.
No where to look for the error.

Despues de intalar la version nueva 2.50, al cerrar el ID da un mensaje de Access Violation, cuando abro mi proyecto, o cuando cambio a otro o cierro.
No da este error si creo un nuevo proyecto en blanco.
No se donde buscar el error.
:evil:

Please Log in or Create an account to join the conversation.

Re: Access Violation when close IDE 12 years 8 months ago #1764

  • Sternas Stefanos
  • Sternas Stefanos's Avatar
  • Offline
  • Moderator
  • Moderator
  • Ex Pilot, M.Sc, Ph.D
  • Posts: 4535
  • Thank you received: 1114
Please Sir
give us more info, your OS etc
PilotLogic Architect and Core Programmer

Please Log in or Create an account to join the conversation.

Re: Access Violation when close IDE 12 years 8 months ago #1766

  • Maximiliano
  • Maximiliano's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 47
  • Thank you received: 3
win7
I found the problem when releasing the DataModule, and zeosconnect component tries to free an object that does not exist, but not created for me

el problema lo encontré cuando se libera el datamodule y la componente de zeosconnect intenta liberar un objeto que no existe pero que no lo cree tampoco

Please Log in or Create an account to join the conversation.

Re: Access Violation when close IDE 12 years 7 months ago #1784

  • ExDatis
  • ExDatis's Avatar
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 110
  • Thank you received: 9
I had the same problem, but only when I used ZEOS. I suggest to use SQLdb, it's
excellent API, fast and easy to use. :sick:

Please Log in or Create an account to join the conversation.

Re: Access Violation when close IDE 12 years 7 months ago #1785

  • Maximiliano
  • Maximiliano's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 47
  • Thank you received: 3
yes is good idea, but sqldb dont run properly the lookup fields in dbgrid.

Please Log in or Create an account to join the conversation.

Re: Access Violation when close IDE 12 years 7 months ago #1786

  • ExDatis
  • ExDatis's Avatar
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 110
  • Thank you received: 9
You do not need that, you can create select sql which looks like view, with fileds you need. In my app I use that solution. :silly:

Please Log in or Create an account to join the conversation.

Re: Access Violation when close IDE 12 years 7 months ago #1787

  • Konstantinos Papadoulas
  • Konstantinos Papadoulas's Avatar
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 131
  • Thank you received: 19
Indeed sometimes SQLite seems to miss some functionality found in other db engines BUT as exdatis suggested it is possible
to overcome these problems using proper SQL statements.

Please Log in or Create an account to join the conversation.

Re: Access Violation when close IDE 12 years 7 months ago #1788

  • Olver Moreno
  • Olver Moreno's Avatar
  • Offline
  • New Member
  • New Member
  • Posts: 8
  • Thank you received: 0
I think the problem is in the way ZEOS create and release the TStringList object where the SQL staments are stored.
In ZeosDB 6.6 this problem does not exist but in ZeosDB 7.0.
The Accesss Violation occurs when the proper component is created and SQL staments are set at design time and later you try
to close de project or when you run the application and try to close it (at least in Ununtu, i'm not trying on Windows yet).
You need to set the SQL statements at Run Time and clear the SQL staments some time before terminate the application( in the
onDestroy event of the form or datamodule, by example).
I test this componets and the properties you need to set:
TZQuery --- TZQuery.SQL.Clear on the OnDestroy event of the datamodule or form.
TZReadOnlyQuery -- .SQL.Clear ........
TZTable -- .TableName:='' ........
TZStoreProc -- .StoredProcName:='' ........

I'll work on this trying to find a better solution on the ZEOS itself, but you can do this way by now.

I'm working in update some modules of ZEOS 7 to work with MS SQL Server from Linux, I do that for ZEOS 6.6 but with CT 2.50 and ZEOS 7
that modifications were not included. When i finish that i'll put the code on the forum and ask Mr. Sternas to include it in the next
CT release like he did with ZEOS 6.6.

Creo que el problema esta en la manera que ZEOS crea y libera el objeto TStringList donde almacena los comandos SQL.
En la versión ZeosDB 6.6 este problema no existía, por lo que es un problema de la ZeosDB 7.0.
El mensaje de Access Violation ocurre cuando el componente es creado y se le asigna el comando SQl en tiempo de diseño y se trata de
cerrar el proyecto o cuando se trata de cerrar la aplicación (al menos asi ocurre en Ubuntu, no lo he probado en Windows todavía) .
Lo que hay que hacer es asignarle el comando SQl al objeto en tiempo de ejecución y despues en algún momento antes de
terminar la ejecución de la aplicación (el evento onDestroy del datamodule por ejemplo), dejar vacia la propiedad del objeto donde se le asigna el comando SQL.
Yo he probado con estos componentes y las propiedades que hay que modificar:
TZQuery --- TZQuery.SQL.Clear en el evento OnDestroy del formulario o datamodule.
TZReadOnlyQuery -- .SQL.Clear ........
TZTable -- .TableName:='' ........
TZStoreProc -- .StoredProcName:='' ........

Yo estoy, dentro de mis posibilidades, tratando de encontar una mejor solución en el código the la ZeosDB, pero de esta manera podemos resolver por ahora.

Yo he estado trabajando en la actualización de algunos modulos de la ZeosDB 7 para que pueda conectarse a MSSqlServer desde Linux,
lo habia hecho ya para ZeosDB 6.6 pero con la versión 2.50 de CT y ZEOS 7 esas modificaciones no se incluyeron. Cuando termine subiré el
código al forum y le pediré al Sr. Sternas que lo incluya en la proxima versión de CT como se hizo con ZeosDB 6.6.

Please Log in or Create an account to join the conversation.

Last edit: by Olver Moreno.

Re: Access Violation when close IDE 12 years 7 months ago #1789

  • Maximiliano
  • Maximiliano's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 47
  • Thank you received: 3
Puede ser que sea eso, pero lo mas raro es que solo abrir y cerrar el proyecto genera el error de access violation. Pero no solo eso sino que me da errores de ejecucion en muchas otras partes. les paso el proyecto para que lo prueban y vean.


It might be that, but more unusual is that only open and close the project generates access violation error. But not only that but it gives me execution errors in many other parts. I pass the project to try it and see.


dl.dropbox.com/u/1641023/TurneroZeos.rar

Please Log in or Create an account to join the conversation.

  • Page:
  • 1