![]() |
Content of documentation | User documentation | Administrator documentation | Index of terms | Technical Support | Search on-line |
Sample applications |
Sample applications are here for two reasons:
You can use and modify them to suit your needs.
1 ... switching to secretary (line 111)
2 ... switching to commercial department (line 225)
3 ... switching to customer support department (line 250)
4 ... leaving a message for line 100
* ... collection of line 100 voice box (this option is not said in the offer)
The options will be repeated twice. If the user selects nothing, the action will be the same as for option "4" – leaving a message. If the user selects any of the options, the playback will stop immediately.
In VoiceChange environment, FLASH is sent as a DTMF character "!". I.e., the switch over of the current call to line 357 will be carried out by means of the following commands:
Line.SendDTMF "!357" Line.Hangup |
samples/autoswitch/
directory
Copy autoswitch.vbs
file into VoiceChange directory and rename to line0.vbs
(or any name for other lines).
Copy the wav/
directory to common/wav/
.
If you want to change the line numbers, correct them in the application code. The same applies to the number of the line, for which the message should be left.
The line, for which the message should be left, should be properly configured (i.e. it should be owned by any e-mail addressee).
The application will ask for the name, company and e-mail of the caller, their phone number (should be entered from the phone keyboard!), related product (1 = FaxChange, 2 = VoiceChange, 3 = MobilChange, 4 = any other product). Then the user is asked to describe the problem.
Then the application will e-mail this information to a specified address.
support_line.vbs
application:
How is the multilingual support ensured? By means of Locale
property of Voice
object. The choice
of the Czech language is carried out by command
Voice.Locale = "cze" |
and from this moment all WAVs are selected from common/wav/cze/
directory. The choice of the English language can be made by means of
Voice.Locale = "eng" |
and all WAVs will be played from common/wav/eng/
directory. For example, after choosing the language at the beginning
of the script, the programmer need not to take care of the language anymore, it is enough to use the same names of WAV files in both
language directories.
Sending of common e-mail with more attachments is base on direct use of VoiceChange COM object Mail and its method SendMessage.
rc = Voice.VXVoice.Mail.SendMessage( _ "administrator@pcbrouzda.syscae.cz", _ "Incomming support call", _ MessageText, _ tempPath & "\ci_name.wav" & ";" _ & tempPath & "\ci_company.wav" & ";" _ & tempPath & "\ci_email.wav" & ";" _ & tempPath & "\ci_problem.wav", _ "" ) |
Further we recommend viewing the function RecordWavEx
(in support_line.vbs
file), which will play the message,
then record WAV, and if it is too long (i.e. the user has hanged up and there is a busy signal on the line) or too short (0.5 sec or less),
it will repeat the whole procedure until the total number of attempts is reached.
samples/support_line/
directory.
Copy support_line.vbs
file to Change directory and rename to line0.vbs
(or any name for other lines).
Copy wav/
directory to common/wav/
.
Set the target e-mail address to line 195 (enter either alias name or e-mail address instead of "Administrator" name).
SendFax()
from COM object Voice.VXVoice
.
This function send a fax within the existing call. The simplest usage of that function follows:
Voice.VXVoice.SendFax "TIFF_to_be_sent.tif" |
More description can be found in documentation.
Document to be send must be "fax" TIFF - with resolution 204x196 DPI, width 1728 pixels, bicolor and with CCITT Fax.G3 or Fax.G4 compression.
TIFF file with this required characteristic can be done for example by printing to FaxChange Client Printer.
samples/fax-on-demand_static/
directory.
Copy fod_static.vbs
file info VoiceChange directory and rename it to
line0.vbs
(or any name for other lines).
Copy wav/
directory into VoiceChange's common/wav/
directory.
Copy common-fax/
directory into VoiceChange's common/fax/
directory.
CnvDoc
.
This object is intended for converting of common documents into TIFF files
by using FaxChange Converter. So it works only if FaxChange Server version 4.0 SP2
or higher is installed at this computer or anywhere in network environment.
Full usage description can be found in documentation. Conversion of one document is done by following function call:
rc = CnvDoc.Convert( _ "c:/dokumenty/source.rtf", _ "c:/temp/to_be_sent.tif", _ 60 ) |
This command will convert file "c:/dokumenty/source.rtf" into TIFF file
"c:/temp/to_be_sent.tif". Timeout is set to sixty seconds; if conversion is not done
within that limit, function will return False
.
samples/fax-on-demand_dynamic/
directory.
Copy fod_dynamic.vbs
file info VoiceChange directory and rename it to
line0.vbs
(or any name for other lines).
Copy wav/
directory into VoiceChange's common/wav/
directory.