Pablo
-
Posts
5 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Posts posted by Pablo
-
-
15 hours ago, Farshad Mohajeri said:
Hi Pablo,
Are these Datamodules created using uniGUI wizard?
Hi Farshad,
I am reusing datamodules that were created in other projects and using directives to create them in my unigui project, example
{$IFDEF UNIGUI}
function DataModule1: TDataModule1;
{$ELSE}for other applications
{$ENDIF}{$IFDEF UNIGUI}
initialization
RegisterModuleClass(TDataModule1);
{$ENDIF}because I need to reuse what I already have an not duplicate it.
What is the solution to the questions asked above?
-
On 3/28/2021 at 9:30 AM, Farshad Mohajeri said:
Datamodules are created and destroyed along with the session.
Hi Farshad, in my case it doesn't happen that way.
I have a datamodule A that uses a datamodule B, are created when you start the session but during the session B is destroyed, I don't know why that happens, finally I get an access violation when trying to access a table.
Is there a way to control the destruction of the datamodule? or know why one of them is destroyed?
-
Sorry I'm using datamodule type
{%CLASSGROUP 'System.Classes.TPersistent'}I need an example of creating datamodule that ends along with the session, that does not make it the same unigui, please example -
Good morning, i am using unigui and normal vcl datamodule started as any unigui datamodule does, creation works correctly. I have global variables that are initialized with the datamodule and I use them to filter data from tables, the problem is that the destroy of the datamodule is executed without having finished the session, they release my global variables and when I try to use them they give me access violation. How can I solve this issue, I thank you in advance for your help
Datamodule is destroyed without ending session time
in General
Posted
Hi Farshad, the zip file Is not available.