f



WIDGET_CONTROL: Invalid widget identifier: 2

Hi, when I run an idl programm (in envi batch mode) a second time in
an idl session, I got the following error: WIDGET_CONTROL: Invalid
widget identifier: 2. I don't think I opened or used any widget in the
programm if this is what it meant. Why am I getting this? Sorry if
this question is too simple and bored you...


Thanks,
Jenny
0
envi35 (50)
12/14/2007 6:58:49 PM
comp.lang.idl-pvwave 12260 articles. 2 followers. Post Follow

2 Replies
633 Views

Similar Articles

[PageSpeed] 59

Jenny writes: 

> Hi, when I run an idl programm (in envi batch mode) a second time in
> an idl session, I got the following error: WIDGET_CONTROL: Invalid
> widget identifier: 2. I don't think I opened or used any widget in the
> programm if this is what it meant. Why am I getting this? Sorry if
> this question is too simple and bored you...

Almost certainly because an info or state structure was
checked out at the top of an event handler with /NO_COPY
and not put back before the event handler was exited. This
is a classic symptom of this error.

Cheers,

David
-- 
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
0
david3553 (839)
12/14/2007 7:43:26 PM
David Fanning writes: 

> Almost certainly because an info or state structure was
> checked out at the top of an event handler with /NO_COPY
> and not put back before the event handler was exited. This
> is a classic symptom of this error.

Or, alternatively, killing the top-level base widget inside
an event handler, and then trying to stick the info structure
into the widget you just killed at the end of the event handler.
If the widget can be killed, then you should check to see if
you have a valid widget id before you try to do something with
it.

Cheers,

David
-- 
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
0
david3553 (839)
12/14/2007 7:48:34 PM
Reply: