Firstly, I’m a newbee so please excuse my ignorance!
I’m trying to set up a tab view so that if the second radio button is clicked then the NSDatePicker will become disabled. I have been trying to use:
on clicked theObject if name of theObject is "i'll set the date" then set enabled of control "date picker" of window "main" to 0 end if
However, I keep getting this error:
It seems to carry out the operation if I use a checkbox instead of the NSDatePicker:
on clicked theObject if name of theObject is "manual" then set enabled of button "check1" of window "main" to 0 end if
I presume I am either addressing the class incorectly, or am I just missing something !?
Also, the datepicker “date picker” is inside a border inside tab view 2 inside window “main” so do i need to make a full reference of that. (I dont with the checkbox.)
OK, I can disable the datepicker via the button if the datepicker is inside window “main” so i guess the problem is the adres of the datepicker,
on clicked theObject if name of theObject is "i'll set the date" then set enabled of control "datepicker" of tab view item "problem" of tab view "info pannels" of box "border" of window "main" to false end if
But i just get a NSReceiverEvaluationScriptError: 4 (1) message when the button is clicked!!
The full script is available if you want to see it (although its probably a bit messy)
Many thanx in advance,
AppleScript: Version 2.1 (80)
Browser: Safari 412.5
Operating System: Mac OS X (10.4)