protected void mvOpenSession_ActiveViewChanged(object sender, EventArgs e)
        {
            switch (mvOpenSession.ActiveViewIndex)
            {
            case 0:     // Incident details
                selectIncident();
                break;

            case 1:     // Contact details
                selectContact();
                break;

            //case 2: // Video session
            //    selectConference();
            //    break;

            case 3:     // Text Chat
                selectTextChat();
                break;


            //case 4: // Screen cast
            //    selectScreenCast();
            //    break;



            case 5:     // Transfer
                selectTransfer();
                break;


            case 6:     // Notes
                selectNotes();
                break;



            case 7:     // AppShare send
                selectAppShareSend();
                break;

            case 8:     // AppShare receive
                selectAppShareReceive();
                break;



            default:
                IncidentHelper.SetIncidentStateInactive(profileId);
                break;
            }
        }
        //-----------------------------------------------------------------------------
        //-----------------------------------------------------------------------------
        //-----------------------------------------------------------------------------

        #endregion



        /////---------------------------------------------------------------------------------



        protected override void save()
        {
            EditContact.Save();
            Int32 contactId = EditContact.ContactId;

            if ((contactId == 0) && (!EditContact.IsAnonymous))
            {
                this.showErrorMessage("Contact must be defined!");
                mvOpenSession.ActiveViewIndex = 1;
            }
            else
            {
                IncidentHelper.SetIncidentStateInactive(profileId);
                EditIncident.Save(contactId);
                InfoAboutCall.Save();

                UcControlArgs args = new UcControlArgs();
                dataSaved(args);

                SaveAudioRecord();
            }
        }