[jawsscripts] Help me to write a particular compound script

  • From: Pradip Chandra Sikdar <pradeepsikdar@xxxxxxxxx>
  • To: jawsscripts@xxxxxxxxxxxxx
  • Date: Tue, 05 Feb 2013 18:00:29 +0530

Dear all!
I am dealing with a script where I have 2 parameters in a *.INI file Like,

[PanelSettings]

FT_Sound=0

FT_Speech=1

I want to make a script and attach a hotkey which do the following:

After Activating the script,

If it finds FT_Sound=1 and FT_Speech=1 then

It will write FT_Sound=0 & FT_Speech=1,

It will Play a particular sound,

It will Say "Speech Only".

But after activating the script,

If it finds FT_Sound=0 and FT_Speech=1 then

It will write FT_Sound=1 & FT_Speech=0,

It will play a sound.,

It will say "Sound Only".

But after activating the script,

If it finds FT_Sound=1 and FT_Speech=0 then

It will write FT_Sound=1 & FT_Speech=1,

It will play a sound,

It will say "Sound and Speech".

I have written a script which compiled successfully. But as I am a 
beginner scripter, I have surely missed something and that's why, I am 
not getting the actual result.

I am pasting the script below. Please correct me.

*Script ConfigureSpeech ()*

*If IniReadInteger ("PanelSettings", "FT_Sound", 1, "Panel.ini") && 
IniReadInteger ("PanelSettings", "FT_Speech", 1, "Panel.ini") then*

*IniWriteInteger ("PanelSettings", "FT_Sound", 0, "Panel.ini")*

*IniWriteInteger ("PanelSettings", "FT_Speech", 1, "Panel.ini")*

*PlaySound (FindJAWSSoundFile ("FT_Mode.wav" )) *

*SayFormattedMessage (OT_JAWS_Message, "Speech Only!")*

*Else*

*If IniReadInteger ("PanelSettings", "FT_Sound", 0, "Panel.ini") && 
IniReadInteger ("PanelSettings", "FT_Speech", 1, "Panel.ini") then*

*IniWriteInteger ("PanelSettings", "FT_Sound", 1, "Panel.ini")*

*IniWriteInteger ("PanelSettings", "FT_Speech", 0, "Panel.ini")*

*PlaySound (FindJAWSSoundFile ("FT_Mode.wav" ))*

*SayFormattedMessage (OT_JAWS_Message, "Sound Only!")*

*Else*

*If IniReadInteger ("PanelSettings", "FT_Sound", 1, "Panel.ini") && 
IniReadInteger ("PanelSettings", "FT_Speech", 0, "Panel.ini") then*

*IniWriteInteger ("PanelSettings", "FT_Sound", 1, "Panel.ini")*

*IniWriteInteger ("PanelSettings", "FT_Speech", 1, "Panel.ini")*

*PlaySound (FindJAWSSoundFile ("FT_Mode.wav" ))*

*SayFormattedMessage (OT_JAWS_Message, "Speech And Sound!")*

*EndIf*

*EndIf*

*EndIf*

*EndScript*

-- 
Regards,
Pradip Chandra Sikdar
Director of Clavier Productions <http://clavierproductions.com>
Keyboard Player, Composer & Sound Editor of X-RaF <http://www.x-raf.com> 
(Experimental Raga and Folk
Catch me on Facebook <http://www.facebook.com/pradip.sikdar>
Follow me on Twitter <http://www.twitter.com/pradeepsikdar>
Website: www.clavierproductions.com <http://clavierproductions.com>
E-mail: pradip@xxxxxxxxxxxxxxxxxxxxxx <mailto:pradip@xxxxxxxxxxxxxxxxxxxxxx>
Skype: pradeep.sikdar
Mobile: +91-9883669711


__________�

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

Other related posts:

  • » [jawsscripts] Help me to write a particular compound script - Pradip Chandra Sikdar