2013-01-05 7 views
-2

Microsoft.office.interop.word 네임 스페이스의 일부인 document.Active() 메서드를 사용하고 있습니다. 파일을 열려고합니다. 즉 Word 응용 프로그램에서 열어 본 파일을보고 싶습니다. 내가 thetrackRevisions 속성을 설정하고 모든 것들의 나머지 부분.MS 워드 파일 열기

그냥 파일을 SAVE-AS 모드로 열려고합니다. DB 또는 PC 드라이브에서 문서를 열면 열어두기 만하면됩니다. 당신의 마음에 와서

Word.Document tempDoc = app.Documents.Open("E:\\xyz.docx"); 
// Activate the document so it shows up in front 
tempDoc.Activate(); 

tempDoc.TrackRevisions = true; 

foreach (Revision rev in tempDoc.Revisions) 
{ 
    string editedBy = rev.Author; 
    //string what = rev.Cells; 
} 

tempDoc.Close(ref Nothing, ref format, ref Nothing); 

어떤 제안 : 여기

내가 실행하고있는 코드는?

답변

0

그냥 단어를여시겠습니까? 해 보셨습니까?

Process.Start ('path to word plus filename');