[jawsscripts] Re: how to type escape characters?

  • From: Andrew Hart <ahart@xxxxxxxxxxxxx>
  • To: jawsscripts@xxxxxxxxxxxxx
  • Date: Fri, 08 Nov 2013 13:11:19 -0300

I just tried it and you can indeed escape the double quote via \", for
example,
QuotedText = "\"Hello, world\""

Cheers.

On 8/11/2013 1:07 PM, Soronel Haetir wrote:
> I am amazed that jaws would support numeric escapes but not direct
> character escape sequences, at  least for those characters that
> commonly need to be escaped, like ".
> 
> On 11/8/13, Jonathan C. Cohn <jon.c.cohn@xxxxxxxxx> wrote:
>> The notation mentioned was originally used in the C programming language but
>> is also available in Perl, java, C++ and several other languages. slash
>> followed by a character is used for tabs and new lines and other frequently
>> used ascii characters. slash followed by a two diget number represents the
>> character as a decimal number. If the first character after the slash is 0
>> then the number is in base 8 instead of decimal, and if the first two
>> characters are 0x then it represents a hexidecimal number.
>>
>> The rest you should be able to find in many programming guides.
>>
>> Jonathan
>>
>>
>> Sent from my iPhone
>>
>>> On Nov 8, 2013, at 7:40 AM, "Paul Magill" <magills@xxxxxxxxxxx> wrote:
>>>
>>> Hi Jeet,
>>>
>>> How it works is more complicated than I can understand, but basically,
>>> the
>>> scripting compiler recognises the backslash character as a marker to
>>> convert
>>> what immediately follows to a specific character in the ASCII series. Not
>>> sure if you were also asking about what ASCII is, but google will have a
>>> bit
>>> to say about that.
>>>
>>> Some of the ones I am familiar with are:
>>> "\N" = line feed or character 10
>>> "\R" = carriage return,  or character 13
>>> The same 2 characters will be produced by:
>>> "\10" = line feed
>>> "\13" = carriage return
>>> "\34" = quote mark
>>> "\\" = the backslash character itself
>>> This one is particularly interesting, as if you wish to hardcode a file
>>> path
>>> in a script, such as "C:\ProgramData\Freedom Scientific\",  in the script
>>> you would need to use double backslashes as, "C:\\ProgramData\\Freedom
>>> Scientific\\", so the compiler would produce the actual path you wanted.
>>>
>>> "\007" = the separation character, LIST_ITEM_SEPARATOR, used in the
>>> function
>>> dlgSelectItemInList. See the entry for that constant in HJCONST.JSH.
>>> When a 0 preceeds a number following the backslash, it changes the way
>>> the
>>> script compiler treats the number, but someone else on the list will need
>>> to
>>> explain that, as while I can use it, I don’t understand it.
>>>
>>> "\999" where 999 represents a number in the ASCII series, from 0 to 255,
>>> causes the compiler to produce the character represented by that number.
>>> For example, 65 is the ASCII number for the upper case, A so "\65" will
>>> produce the letter A.
>>>
>>> Note, the compiler mostly knows when to stop the conversion.
>>> In my previous example, "\34(", the compiler converts only the \34, and
>>> uses
>>> the ( as it is.
>>> When using the line feed in a longer string, such as, "first line\Nsecond
>>> line",  to be used in one of the Jaws dialog boxes, the compiler only
>>> converts the \N, and the result on screen is:
>>> first line
>>> second line
>>>
>>> Hope this helps,
>>> Paul from Australia
>>>
>>> -----Original Message-----
>>> From: Jitendra
>>> Thanks, it did the trick but what is \34, is the ascii value?
>>>
>>> and why we need include the back slash?
>>> thanks, Jeet
>>> Paul Magill wrote:
>>>> Hi Jitendra,
>>>>
>>>> In a const statement:
>>>>
>>>> Const
>>>> Quote = "\34",
>>>> QuoteAndLeftParenthesis = "\34(",
>>>>
>>>> Or
>>>>
>>>> TypeString ("\34(whatever else")
>>>>
>>>> The number following the backslash is the ascii value.
>>>>
>>>> Regards
>>>> Paul from Australia
>>>>
>>>> -----Original Message-----
>>>> From: jawsscripts-bounce@xxxxxxxxxxxxx
>>>> [mailto:jawsscripts-bounce@xxxxxxxxxxxxx] On Behalf Of Jitendra
>>>> Sent: Thursday, 7 November 2013 8:31 PM
>>>> To: jawsscripts@xxxxxxxxxxxxx
>>>> Subject: [jawsscripts] how to type escape characters?
>>>>
>>>> Hello friends, this time I need your help, if I want JAWS to type
>>>> characters like " (quotes, left or right parrant or any other escape
>>>> character, how should I do that?
>>>> Var string s
>>>> ;for example, Change is a function's name in a company software, and
>>>> you need to type again and again, and a value should be supplied in
>>>> quotes to change colors, Ii want JAWS to type the half part of the
>>> function.
>>>> s = "Change(""
>>>> TypeString(s)
>>>> Thanks.
>>>>
>>>> --- Disclaimer --- The information in this mail is confidential and is
>>>> intended solely for addressee. Access to this mail by anyone else is
>>>> unauthorised. Copying or further distribution beyond the original
>>>> recipient may be unlawful. Any opinion expressed in this mail is that
>>>> of sender and does not necessarily reflect that of State Bank group.
>>>> --- __________�
>>>>
>>>> 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
>>>
>>>
>>> --- Disclaimer --- The information in this mail is confidential and is
>>> intended solely for addressee. Access to this mail by anyone else is
>>> unauthorised. Copying or further distribution beyond the original
>>> recipient
>>> may be unlawful. Any opinion expressed in this mail is that of sender and
>>> does not necessarily reflect that of State Bank group. --- __________�
>>>
>>> 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
>>>
>> __________�
>>
>> 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: