1

Topic: Questions on operation with flows

All kind day!
Never before with flows worked, therefore there is a pair of questions... There is a flow which does the same operation on time.
Pulls out the data from DB Firebird and saves in a file of Eksel. Costs FreeOnTerminate: = true, that is I launch it, further it is not necessary to me.
In this connection a question:
1) At program termination, I somehow should complete forcedly a flow if suddenly it works at present? Or Delfi the automatic machine kills him at an output?
2) Found that in a flow it is necessary to create the copy of session for a connection to basis... Whether Really it is necessary? Now works and so

2

Re: Questions on operation with flows

aidynchik;
To cause terminate - in a flow, and further wait. And in a flow to process property terminated.
And in a case if terminated =true - to finish all actions in a flow.

3

Re: Questions on operation with flows

Whether

aidynchik wrote:

Really it is necessary?

It is not necessary, if to this connection anywhere calls are not present, except this flow.

4

Re: Questions on operation with flows

aidynchik wrote:

1) At program termination, I somehow should complete forcedly a flow if suddenly it works at present? Or Delfi the automatic machine kills him at an output?

will wait its terminations. If it is necessary to supervise it it is necessary to leave from FreeOnTerminate.

5

Re: Questions on operation with flows

Zelius;
No, it is not necessary to supervise, fulfilled and it is fine... Simply I carried out the test, got there an infinite loop and quitted the program -  closed application waiting of nothing. Basically it suits me - the memory leak main point will not be in this case?
wadman;
Reversal is, application itself works through this connection... It turns out it is necessary to create one more copy FIBDatabase? And how it is better to connect to it, each time at flow creation, or it is better once  and  only at application closing?

6

Re: Questions on operation with flows

aidynchik wrote:

It turns out it is necessary to create one more copy FIBDatabase?

The problem to throw one more component on the form? smile

aidynchik wrote:

And how it is better to connect to it, each time at flow creation, or it is better once  and  only at application closing?

And as you want. To create each time is hardly more unprofitable, than once for all time.
On the other hand there are less than overlays/loadings in the form of eternally hanging connection.

7

Re: Questions on operation with flows

aidynchik;
With threads, .

8

Re: Questions on operation with flows

[quote =] Simply I carried out the test, got there an infinite loop and quitted the program -  closed application waiting of nothing. Basically it suits me - the memory leak main point will not be in this case?

will not be.