private void UpdateDialPlanCompleted(object sender, UpdateDialPlanCompletedEventArgs e)
 {
     if (IsUnauthorised(e.Error))
     {
         SessionExpired();
     }
     else if (UpdateDialPlanComplete != null)
     {
         UpdateDialPlanComplete(e);
     }
     ;
 }
        private void UpdateDialPlanComplete(UpdateDialPlanCompletedEventArgs e)
        {
            try
            {
                // The Dial Plan returned by the web service call is the account after the update operation was carried out.
                SIPDialPlan dialPlan = e.Result;

                if (m_editControl != null)
                {
                    m_editControl.WriteStatusMessage(MessageLevelsEnum.Info, "Update completed successfully for " + dialPlan.DialPlanName + ".");
                }
            }
            catch (Exception excp)
            {
                string excpMessage = (excp.InnerException != null) ? excp.InnerException.Message : excp.Message;

                if (m_editControl != null)
                {
                    m_editControl.WriteStatusMessage(MessageLevelsEnum.Error, "There was an error performing a Dial Plan update." + excpMessage);
                }
                else
                {
                    LogActivityMessage_External(MessageLevelsEnum.Error, "There was an error performing a Dial Plan update." + excpMessage);
                }
            }
        }
 private void UpdateDialPlanCompleted(object sender, UpdateDialPlanCompletedEventArgs e) {
     if (IsUnauthorised(e.Error)) {
         SessionExpired();
     }
     else if (UpdateDialPlanComplete != null) {
         UpdateDialPlanComplete(e);
     };
 }