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

Home » Public Forums » archive » Re: always widget!
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: always widget! [message #37426] Thu, 18 December 2003 04:59 Go to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Roberto writes:

> How could I know if a widget is active?
> In my widget I have a widget_Text (text1) and two widget_button (butto1, button2).
> Button1 is used to activate or disactivate text1. I use this code:
> [.....]
> WIDGET_CONTROL, event.id, GET_UVALUE = eventval
> CASE eventval OF
> "button1" : BEGIN
> if (event.select eq 1) then begin
> widget_control, text1, sensitive = 0
> endif else begin
> widget_control, text1, sensitive = 1
> endelse
> END
> [......]
>
> by button2 I want to know if text1 is active or not.
> How can I do?

You can use WIDGET_INFO:

Print, WIDGET_INFO(text2, /Sensitive)

Cheers,

David
--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http:/www.dfanning.com/
Phone: 970-221-0438, IDL Book Orders: 1-888-461-0155
Re: always widget! [message #37513 is a reply to message #37426] Fri, 19 December 2003 00:42 Go to previous message
templebar is currently offline  templebar
Messages: 6
Registered: October 2003
Junior Member
Thank you David!
Keyword SENSITIVE is not allowed in WIDGET_INFO function but I have
resolved equally!
Good festivities!
Roberto
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Array has too many elements?
Next Topic: Error in georeferencing using map_patch?

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

Current Time: Sat Oct 11 08:41:51 PDT 2025

Total time taken to generate the page: 0.79623 seconds