예제 #1
0
        private void OnAddWord(object obj)
        {
            var openFileDialog = new OpenFileDialog {Filter = "WORD文档|*.docx"};
            if (openFileDialog.ShowDialog() != true) return;
            listDocuments = ServiceLocator.Current.GetInstance<ListDocuments>();
            listDocuments.Close();

            docViewer.ShowDialog();
            docViewerVM.InitDocument(openFileDialog.File, windowClosed, DocTypeIds);
        }
예제 #2
0
        /// <summary>
        ///     本地添加附件
        /// </summary>
        /// <param name="sender">命令参数</param>
        protected void OnAddLocalAttach(object sender)
        {
            var openFileDialog = new OpenFileDialog {Filter = "可用文档|*.docx;*.pdf"};
            if (openFileDialog.ShowDialog() != true) return;
            listDocuments = ServiceLocator.Current.GetInstance<ListDocuments>();
            listDocuments.Close();

            docViewer.ShowDialog();
            docViewerVM.InitDocument(openFileDialog.File, windowClosed, DocTypeIds);
        }