There's NO multitasking going on in my program, but I have a couple of
multitasking related problems. I can provide a good deal more information to
help sort out this issue if it's possibly related to oodialog 4.2.0 beta,
but it's not just a matter of cutting and pasting a few lines of code, so to
save you (and me!) from lots of digging, my initial query is simply .
Are there any known problems in the beta so far relating to either "deadlock
detected" or user routines simply stopping dead waiting for resources
belonging to other user classes?
One quick example .
(It's for my driving school, and this bit is creating a new lesson in my
diary. I want to select from a list of active pupils, but I have checkboxes
so that I can also select from pupils who have passed their driving test or
who I've marked "dormant" because I haven't seen them for a while.)
::method SetupNewLesson -- called from initdialog
expose mainmenu
self~activetick = .true -- these are from checkboxes on the dialog
self~passedtick = .false
self~dormanttick = .false
self~SetupPupilCombo
::method setuppupilcombo -- called from setupnewlesson or after a checkbox
is changed.
expose mainmenu
del = self~getcomboitems(100)
say "Deleting" del "items"
do d = del to 1 by -1
say "RC="self~deletecomboentry(100,d) "("d")"
end d
do p = 1 to mainmenu~pupils
-- this is the problem line
if (mainmenu~pupil[p]["status"] = "Active" & self~activetick = .true) |,
(mainmenu~pupil[p]["status"] = "Passed" & self~passedtick = .true) |,
(mainmenu~pupil[p]["status"] = "Dormant" & self~dormanttick = .true),
then do
say "Adding" mainmenu~pupil[p]["name"] "..."
self~addcomboentry(100,mainmenu~pupil[p]["name"])
end
end p
On the first call (from initdialog), the seupnewlesson method calls
setuppupilcombo and all is well. The combobox contains a list of "active
pupils".
If I check or uncheck any of the 3 checkboxes (active/passed/dormant) the
setuppupilcombo method gets called to remove all the pupil names from the
combo and add a new list of names based on whether their status is active,
passed or dormant. On this second call, the method stops at the marked
"problem line" seemingly waiting for the pupils attribute of the mainmenu
class to become free. Control returns to the dialog with an empty combobox
and all controls on the dialog are unresponsive. If I press ESC to quit the
dialog, control returns to the parent window but all the queued methods get
called and they fail because the dialog has ended.
Putting a "trace I" just above the problem line gives this output from the
2nd call of setuppupilcombo
Deleting 11 items
RC=10 (11)
RC=9 (10)
RC=8 (9)
RC=7 (8)
RC=6 (7)
RC=5 (6)
RC=4 (5)
RC=3 (4)
RC=2 (3)
RC=1 (2)
RC=0 (1)
2157 *-* do p = 1 to mainmenu~pupils
>L> "1"
>V> MAINMENU => "a MAINMENU"
And this is where the trace pauses until I end the dialog, then the trace
continues, trying to add the relevant pupils to the combobox.
The other problem is intermittent, and would take quite some explaining, but
it results in program termination with a message like "deadlock detected in
guarded method". I don't seem to be able to recreate that one now!
Back to the main point - my problem or a problem with oodialog?
Thanks,
Dave Dawson
------------------------------------------------------------------------------
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
_______________________________________________
Oorexx-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/oorexx-users