Board index » delphi » Please Help - System Illegally Reentered

Please Help - System Illegally Reentered

Well, I'm torched, exhausted and almost ready to heave a large object
through my monitor screen.

 Having battle this problem on an off for several weeks (and thinking
I beat it), it's back and I haven't a clue why.  Can someone please
shed some light on this problem?

Scenario - I have an MDI application where the child windows make
calls to both local tables (aka Paradox) and, occassionally, to an
AS/400 table.  We use the CO/400 objects to make a call to the AS/400
and then I use a query (running in a seperate thread), to download the
AS/400 table.  Once the table is 400 table is converted to Paradox 7
format, I perform additional computation on the local table to produce
another table in the format which I want to display.  When a single
MDI child is active, I don't encounter ANY problems.

Now, here's the problem.  Let's say I open a second MDI child.  My
tables are transferred and transformed correctly to display in the new
window.  But, if I switch back to the other form and attempt to run
the query associated it with it, BAM! I get an error "System Illegally
Reentered".  I have no recourse at this point but to terminate the
program and reboot.

I've stepped through the code and even found  exactly where it
bombs....at the call to my data transformation.  All of the parameters
I am passing in are all okay...nothing has been freed.

Someone said that it may have to do something with sessions.  How?
And, how do I stop this incideous problem from reoccuring?

Please..SOMEBODY HELP!

Charles

 

Re:Please Help - System Illegally Reentered


I had a situation using a single session, a query and a registered bde
callback
Every now and then while I was processing the callback I would get this
"system illegally reentered" error. I traced it to a timer where I was
checking to
see how many records were in a file. The cure was to either create another
session or to block the timer from checking while running the query.

Garry Kernan

Quote
Charles Stack wrote in message <6tp6pc$3e...@forums.borland.com>...
>Well, I'm torched, exhausted and almost ready to heave a large object
>through my monitor screen.

> Having battle this problem on an off for several weeks (and thinking
>I beat it), it's back and I haven't a clue why.  Can someone please
>shed some light on this problem?

>Scenario - I have an MDI application where the child windows make
>calls to both local tables (aka Paradox) and, occassionally, to an
>AS/400 table.  We use the CO/400 objects to make a call to the AS/400
>and then I use a query (running in a seperate thread), to download the
>AS/400 table.  Once the table is 400 table is converted to Paradox 7
>format, I perform additional computation on the local table to produce
>another table in the format which I want to display.  When a single
>MDI child is active, I don't encounter ANY problems.

Re:Please Help - System Illegally Reentered


Thanks for the input.   At least I'm not alone.  Unfortunately, I'm not
using a BDE Callback (I'm using TQuery/TwwQuery components).  And, I don't
allocate a timer.  Guess that means a seperate Session for each dataset
component.  THAT could get pretty messy.  Any other ideas?

Charles

Other Threads