Re: Setting the value of a button hilite in script

2011-12-15 Thread J. Landman Gay
On 12/15/11 8:36 AM, Ken Ray wrote: Let's have a gathering at the next conference and confess our stupid moments. I bet we'd draw a huge crowd. We could give a "Most Stupid" award. I've got a really good entry. Sounds like a *great* idea! Not only will it be humorous, but it will also be very i

Re: Setting the value of a button hilite in script

2011-12-15 Thread Ken Ray
> Let's have a gathering at the next conference and confess our stupid moments. > I bet we'd draw a huge crowd. We could give a "Most Stupid" award. I've got a > really good entry. Sounds like a *great* idea! Not only will it be humorous, but it will also be very informative. I'm in! :D Ken R

Re: Setting the value of a button hilite in script

2011-12-14 Thread Bob Sneidar
Honorable Mention can be "Most Stupid Looking". I'll bring a photo... Bob On Dec 14, 2011, at 1:50 PM, J. Landman Gay wrote: > Let's have a gathering at the next conference and confess our stupid moments. > I bet we'd draw a huge crowd. We could give a "Most Stupid" award. I've got a > really

Re: Setting the value of a button hilite in script

2011-12-14 Thread J. Landman Gay
On 12/14/11 3:10 PM, Mark Wieder wrote: Jacque- Wednesday, December 14, 2011, 10:34:59 AM, you wrote: Oh good, that's easy to fix. Glad you found it. And don't feel bad, I once submitted a bug report about the same thing back in the MetaCard days. Dr Raney pointed out my error and I was embarr

Re: Setting the value of a button hilite in script

2011-12-14 Thread Mark Wieder
Jacque- Wednesday, December 14, 2011, 10:34:59 AM, you wrote: > Oh good, that's easy to fix. Glad you found it. And don't feel bad, I > once submitted a bug report about the same thing back in the MetaCard > days. Dr Raney pointed out my error and I was embarrassed for days. I just reported a bu

Re: Setting the value of a button hilite in script

2011-12-14 Thread J. Landman Gay
On 12/14/11 12:08 PM, Pete wrote: Never mind folks, found the problem - a missing break in a switch statement (how many times has that bitten me!). Sorry for the trouble. Oh good, that's easy to fix. Glad you found it. And don't feel bad, I once submitted a bug report about the same thing bac

Re: Setting the value of a button hilite in script

2011-12-14 Thread Pete
Never mind folks, found the problem - a missing break in a switch statement (how many times has that bitten me!). Sorry for the trouble. Pete On Tue, Dec 13, 2011 at 9:37 PM, Mark Wieder wrote: > Pete- > > Tuesday, December 13, 2011, 5:23:11 PM, you wrote: > > > Hi Mark, > > That's where I star

Re: Setting the value of a button hilite in script

2011-12-14 Thread Robert Brenstein
On 13.12.2011 at 22:15 Uhr -0800 Pete apparently wrote: Very strange. As mentioned, I got round the problem by using a do command: do "set the hilite of control x of this card to" && the cInitialValue of control x of this card That worked with no other changes to the overall logic of the handl

Re: Setting the value of a button hilite in script

2011-12-13 Thread Pete
Very strange. As mentioned, I got round the problem by using a do command: do "set the hilite of control x of this card to" && the cInitialValue of control x of this card That worked with no other changes to the overall logic of the handler in detecting what type of control I'm dealing with. Pe

Re: Setting the value of a button hilite in script

2011-12-13 Thread J. Landman Gay
On 12/13/11 11:37 PM, Mark Wieder wrote: Pete- Tuesday, December 13, 2011, 5:23:11 PM, you wrote: Hi Mark, That's where I started - I added the parens to see if it made any difference. I just tried it again without the parens and still get the same error. Wonder if it's a version thing - I'm

Re: Setting the value of a button hilite in script

2011-12-13 Thread Mark Wieder
Pete- Tuesday, December 13, 2011, 5:23:11 PM, you wrote: > Hi Mark, > That's where I started - I added the parens to see if it made any > difference. I just tried it again without the parens and still get the > same error. Wonder if it's a version thing - I'm on 4.6.4 I did that on 4.6.4 as we

Re: Setting the value of a button hilite in script

2011-12-13 Thread Pete
Thanks for the suggestions Phil. I'm attempting to put initial values into all the controls on the card not just buttons. My code figures out what type of control it's dealing with by looking at the first word of the abbrev name, then the menumode and style if it's a button. Once it's figured ou

Re: Setting the value of a button hilite in script

2011-12-13 Thread Phil Davis
Hi Pete, I'm not always good at staying on-topic, but maybe some of this will help... On 12/13/11 2:50 PM, Pete wrote: I wrote myself a script to set the initial values of controls on a card in preOpenCard. It looks for a custom property name cInitialValue, then initialises the control to the

Re: Setting the value of a button hilite in script

2011-12-13 Thread Pete
Hi Mark, That's where I started - I added the parens to see if it made any difference. I just tried it again without the parens and still get the same error. Wonder if it's a version thing - I'm on 4.6.4 On Tue, Dec 13, 2011 at 5:01 PM, Mark Wieder wrote: > Pete- > > Try it without the parenth

Re: Setting the value of a button hilite in script

2011-12-13 Thread Mark Wieder
Pete- Try it without the parentheses. It's kind of unpredictable when they'll work and when they won't. This works for me where the parenthetical one gives me an error. set the hilite of control x of this card to the cInitialValue of \ control x of this card -- -Mark Wieder mwie...@ahsoftware.

Re: Setting the value of a button hilite in script

2011-12-13 Thread Pete
l check for empty in the cprop and ignore it if so. The control that's being processed when I get the error is a checkbox. I don't get any errors on other type of controls except checkboxes and radio buttons when trying to set their hilite. On Tue, Dec 13, 2011 at 3:02 PM, J. Landman Gay wrote:

Re: Setting the value of a button hilite in script

2011-12-13 Thread Bob Sneidar
Hmmm... breakpoint in the loop and check that the control you think you are setting is actually a checkbox or radio button, then make sure the property is what you think it is. Also check for a carriage return in the property. That bit me in the butt recently. Bob On Dec 13, 2011, at 2:50 PM

Re: Setting the value of a button hilite in script

2011-12-13 Thread J. Landman Gay
On 12/13/11 4:50 PM, Pete wrote: I wrote myself a script to set the initial values of controls on a card in preOpenCard. It looks for a custom property name cInitialValue, then initialises the control to the value of the custom property, depending on that type of control (field, button, etc). I