comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Clearing widget_list of all entries
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: Clearing widget_list of all entries [message #18937] Thu, 17 February 2000 00:00
Robert Weiss is currently offline  Robert Weiss
Messages: 5
Registered: February 2000
Junior Member
David Fanning wrote:

> Robert Weiss (weiss@mpia-hd.mpg.de) writes:
>
>> Does anyone of you know a way to clear a widget_list of all items ?
>> Using widget_control with set_value doesn't work since no string arrays
>> of zero
>> length are permitted in IDL.
>
> I should think Widget_Control, listWidgetID, Set_Value="" would
> do pretty much what you want. With, perhaps, some kind of
> check in the list event handler to not respond to any
> event that generated a null string for a value.

That's quite similar to what I did already (setting sensitivity to 0 for
lists containing only an empty string)
... I just felt it would be a nice (and logical) feature for
a list widget to be "emptiable" ;-) ... AND zero length arrays would come
in handy for a couple
of other problems as well (does anyone at RSI read this newsgroup?),

however, thanks a lot,
Robert.
Re: Clearing widget_list of all entries [message #18938 is a reply to message #18937] Thu, 17 February 2000 00:00 Go to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Robert Weiss (weiss@mpia-hd.mpg.de) writes:

> Does anyone of you know a way to clear a widget_list of all items ?
> Using widget_control with set_value doesn't work since no string arrays
> of zero
> length are permitted in IDL.

I should think Widget_Control, listWidgetID, Set_Value="" would
do pretty much what you want. With, perhaps, some kind of
check in the list event handler to not respond to any
event that generated a null string for a value.

Or, if even this was too much list, you could put the list
widget in a bulletin-board base and simply unmap the base
widget. This would make the whole thing disappear, no matter
how many list items it contained.

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: vector print bug ?
Next Topic: Clearing widget_list of all entries

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 19:47:15 PDT 2025

Total time taken to generate the page: 0.00462 seconds