[jawsscripts] Re: correct syntactical use of int variable flags?

  • From: "Geoff Chapman" <gch@xxxxxxxxxxxxxxxx>
  • To: <jawsscripts@xxxxxxxxxxxxx>
  • Date: Fri, 2 Jul 2010 08:51:26 +1000

cool, yep, ok Jim will do. thanks for this eh.


----- Original Message ----- 
From: "Homme, James" <james.homme@xxxxxxxxxxxx>
To: <jawsscripts@xxxxxxxxxxxxx>
Sent: Wednesday, June 30, 2010 10:57 PM
Subject: [jawsscripts] Re: correct syntactical use of int variable flags?


> Hi Geoff,
> About the true false thing. Previously you said that any non-zero value is
true. Actually, in JAWSVille, you can look in HJConst.jsh for two constants.
One is true, set to the number 1. The other is false, set to the number 0,
so be careful. If you really want to check for a non-zero value by using a
short hand thingy, use code that looks like this.
>
> If iNumber then
> do my thing
> endif
>
> Jim
>
>
> Jim Homme,
> Usability Services,
> Phone: 412-544-1810. Skype: jim.homme
> Internal recipients,  Read my accessibility blog. Discuss accessibility
here. Accessibility Wiki: Breaking news and accessibility advice
>
> -----Original Message-----
> From: jawsscripts-bounce@xxxxxxxxxxxxx
[mailto:jawsscripts-bounce@xxxxxxxxxxxxx] On Behalf Of Geoff Chapman
> Sent: Wednesday, June 30, 2010 12:37 AM
> To: jawsscripts@xxxxxxxxxxxxx
> Subject: [jawsscripts] Re: correct syntactical use of int variable flags?
>
> cool! yep thanks for clarification.
>
> I know how to use those, but, just got a bit confused I think, re the
> treu/false, 1/0 thang.
>
> but, I get confused easily these days. my brain is wearing out I think.
What
> did ;pascale say? or was it day cart, )spelt wrong,) I think, therefore
I'm
> not? think that was it eh. hee hee.
>
> don't mind me. <grin.>
>
> ----- Original Message -----
> From: "Jackie McBride" <abletec@xxxxxxxxx>
> To: <jawsscripts@xxxxxxxxxxxxx>
> Sent: Tuesday, June 29, 2010 3:20 PM
> Subject: [jawsscripts] Re: correct syntactical use of int variable flags?
>
>
> > The whole true/false thing is just meant to apply when the complexity
> > requires only a true/false test.
> >
> > Sounds like u need the if/elif/else/endif as follows:
> > if (iVarName == 1) then
> > DoThis()
> > elif
> >   (iVarName == 2) then
> >   doThat()
> > elif
> >   (iVarName == 3) then
> >   DoTheOtherThing()
> > else
> >   forgetIt()
> > endif
> >
> > On 6/28/10, Geoff Chapman <gch@xxxxxxxxxxxxxxxx> wrote:
> >> Mighty scripters.
> >>
> >> May I ask yet another question?
> >> I've read somewhere, that in integer flag land, setting an int variable
> >> to
> >> 0,equates to a, "false", condition? and setting it to 1, or indeed
> >> anything
> >> other than 0, relligates it to a, "treu," condition.
> >> And that these are often used to set the, yes, or no, as to whether
other
> >> things should happen, or functions should run etc.
> >>
> >> So, sorry, but just absolutely clarifying things in my slow processing
> >> head
> >> on this here, I'm just struggling to specificly fit in how exactly this
> >> concept morphs, with what I believe, and have experienced,
> >> is also possible, and that is the situations
> >> where one has not just two conditions to flag, but more than two?
where,
> >> one
> >> thus may wish to set such a variable flag, not just to 0, false, or 1,
> >> true,
> >> but, say, to 2, which means, do something else?
> >>
> >> or is that whole true/false condition thing, just meant to apply in
cases
> >> where nothing more complex is needed than just a 1 or 0 state of
things?
> >> If that even makes sense?
> >>
> >> I know, it's a bit, meta, but, I just like to try and get these things
> >> totally straight in my brain.  There's quite a lot of stuff like this
> >> still
> >> unsettled in my head right now, but, I am learning. thanks to you all.
> >> oh, and if your all getting a bit tired of my constant, (or variable,
hee
> >> hee,)
> >>  questions by now, I do sympathise with you, and can only encourage you
> >> by
> >> saying, that this job should be over soon, and you/we'll all get a bit
of
> >> a
> >> rest then! <grin.>
> >>
> >> Thanks for any clarifications.
> >>
> >>
> >>
> >>
> >> __________�
> >>
> >> View the list's information and change your settings at
> >> http://www.freelists.org/list/jawsscripts
> >>
> >>
> >
> >
> > --
> > Change the world--1 deed at a time
> > Jackie McBride
> > www.abletec.serverheaven.net
> > Please join me Saturday, 11/7, on my walk against breast cancer by
> > making a donation at:
> > http://main.acsevents.org/goto/larkspur>
> > __________�
> >
> > View the list's information and change your settings at
> > http://www.freelists.org/list/jawsscripts
> >
>
> __________�
>
> View the list's information and change your settings at
> http://www.freelists.org/list/jawsscripts
>
>
> This e-mail and any attachments to it are confidential and are intended
solely for use of the individual or entity to whom they are addressed.  If
you have received this e-mail in error, please notify the sender immediately
and then delete it.  If you are not the intended recipient, you must not
keep, use, disclose, copy or distribute this e-mail without the author's
prior permission.  The views expressed in this e-mail message do not
necessarily represent the views of Highmark Inc., its subsidiaries, or
affiliates.
> __________�
>
> View the list's information and change your settings at
> http://www.freelists.org/list/jawsscripts
>

__________�

View the list's information and change your settings at 
http://www.freelists.org/list/jawsscripts

Other related posts: