//保存编辑
 private void btnSave_Click(object sender, EventArgs e)
 {
     try
     {
         ICommand m_saveEditCom = new SaveEditCommandClass();
         m_saveEditCom.OnCreate(pMapControl.Object);
         m_saveEditCom.OnClick();
         SysLogHelper.WriteOperationLog("数据管理-数据编辑", "保存编辑", "数据管理");
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
         PS.Plot.Common.LogHelper.WriteLog(typeof(Form_Editor), ex, "保存编辑");
     }
 }
        public void OnClick()
        {
            m_Map          = m_hookHelper.FocusMap;
            m_activeView   = m_Map as IActiveView;
            m_EngineEditor = MapManager.EngineEditor;
            Boolean bSave = true;

            if (m_EngineEditor == null)
            {
                return;
            }
            if (m_EngineEditor.EditState != esriEngineEditState.esriEngineStateEditing)
            {
                return;
            }
            IWorkspaceEdit pWsEdit = m_EngineEditor.EditWorkspace as IWorkspaceEdit;

            if (pWsEdit.IsBeingEdited())
            {
                Boolean bHasEdit = m_EngineEditor.HasEdits();
                if (bHasEdit)
                {
                    if (MessageBox.Show("是否保存所做的编辑?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.Yes)
                    {
                        bSave = true;
                        SysLogHelper.WriteOperationLog("数据管理-数据编辑", "保存并停止编辑", "数据管理");
                    }
                    else
                    {
                        bSave = false;
                        SysLogHelper.WriteOperationLog("数据管理-数据编辑", "停止编辑未保存", "数据管理");
                    }
                }
                m_EngineEditor.StopEditing(bSave);
            }
            m_Map.ClearSelection();
            m_activeView.Refresh();
        }