저는이 확장의 일부로 Interop 어셈블리를 사용하는 사무실 용 확장 프로그램에서 작업하고 있습니다. 빌드하는 EXE의 주요 목표는 PPTX 슬라이드를 개별 이미지로 내보내는 것입니다.C# SteamWriter : 여러 텍스트 파일을 만들고 쓰는 방법?
각 슬라이드에 정보가 포함 된 텍스트 파일을 만들고 싶습니다. 슬라이드를 내보낼 수 있습니다. 또한 하나의 텍스트 파일을 만들지 만 아무것도 쓰지 않습니다. 각 파일은이 파워 포인트에 의해 색인 때문에 ... 미안, 내가 잃어버린하고있어
class {
static void ConvertAndExportImagesAndTextFiles(ARGS){
//Some stuff that reads and prepares the slides for the export method
//Loops and exports several "objSlide" after taking args
foreach (Microsoft.Office.Interop.PowerPoint.Slide objSlide
in objActivePresentation.Slides)
{
i++;
string PathAndNumber = string.Concat(FilePath, i);
string PathAndNumberWithExt = string.Concat(PathAndNumber, ".txt");
FileStream fs = new FileStream(
PathAndNumberWithExt ,
FileMode.OpenOrCreate,
FileAccess.ReadWrite);
StreamWriter sw = new StreamWriter(fs);
try
{
sw.WriteLine("Howdy World.");
}
finally
{
?????????
}
objSlide.Export(FilePath, format, res, res);
}
... 1.TXT, 2.txt로 슬라이드 수출을 수출,하지만 뭔가를 incmnt해야해야 이리?
고맙습니다. :) –