protected override void OnStartProcessing(TelecomScriptInterface tsInterface, CallButler.Telecom.TelecomProviderBase telecomProvider, WOSI.CallButler.Data.DataProviders.CallButlerDataProviderBase dataProvider) { tsInterface.IMLInterpreter.DefaultSpeechVoice = Properties.Settings.Default.DefaultTTSVoice; // Set our volumes telecomProvider.SetRecordVolume(tsInterface.LineNumber, Properties.Settings.Default.RecordVolume); telecomProvider.SetSoundVolume(tsInterface.LineNumber, Properties.Settings.Default.SoundVolume); telecomProvider.SetSpeechVolume(tsInterface.LineNumber, Properties.Settings.Default.SpeechVolume); string extensionFinderScriptLocation = WOSI.Utilities.FileUtils.GetApplicationRelativePath(Properties.Settings.Default.SystemScriptsRootDirectory) + "\\Extension Finder.xml"; if (File.Exists(extensionFinderScriptLocation)) { onholdTsInterface.IMLInterpreter.SyncExternalAction += new EventHandler<WOSI.IVR.IML.SyncExternalActionEventArgs>(IMLInterpreter_SyncExternalAction); IMLScript imlScript = IMLScript.OpenScript(extensionFinderScriptLocation); // Get our call script element ScriptElement[] callElements = imlScript.GetAllElementsOfType(typeof(Call)); if (callElements != null && callElements.Length > 0) { callScriptElement = (Call)callElements[0]; } extensionNumberIndex = -1; this.tsInterface = tsInterface; // Copy our variables tsInterface.IMLInterpreter.MergeLocalVariables(onholdTsInterface.IMLInterpreter); tsInterface.IMLInterpreter.SetLocalVariable("ExtensionTimeout", "20"); tsInterface.IMLInterpreter.StartScript(imlScript, WOSI.Utilities.FileUtils.GetApplicationRelativePath(Properties.Settings.Default.SystemScriptsRootDirectory)); // Tell our extension that they have an incoming call //CallInfo callInfo = new CallInfo(tsInterface.CurrentCallID, tsInterface.LineNumber, CallStatus.Incoming, onholdTsInterface.IMLInterpreter.CallerDisplayName, onholdTsInterface.IMLInterpreter.CallerUsername); //extStateService.UpdateCallState(extension.ExtensionID, callInfo); } }