Component Object Model Experiments

PDF Creator

<< NETLink`

InstallNET[]

pc = CreateCOMObject["PDFCreator.clsPDFCreator"]

opts=pc@cOptions

opts@AutosaveFilename = "test"

opts@AutosaveFilename

pc@cSaveOptions[opts]

pc@cStart["/NoProcessingAtStartup"]

OneNote

Following http : // msdn.microsoft.com/en - us/library/ms788684.aspx

<< NETLink`
InstallNET[];
on=CreateCOMObject["OneNote.Application"]

If[!NETObjectQ[on], $Failed,
on@OpenHierarchy[
"C:\\drorbn\\AcademicPensieve\\PublicNotebook\\2008-11.one",
"",
doc
];
on@Publish[
doc,
"C:\\drorbn\\AcademicPensieve\\PublicNotebook\\Annotations\\views\\EtingofKazhdan.pdf",
3,
""
]
]

on@OpenHierarchy[
"C:\\drorbn\\AcademicPensieve\\PublicNotebook\\2008-11.one",
"",
doc
]; doc

on@GetPageContent[doc, content]; content

on@Publish[
"{86FD7ADA-4EB7-4BF7-B536-E1DFC98E771B}{1}{B0}",
"C:\\drorbn\\AcademicPensieve\\PublicNotebook\\Annotations\\views\\EtingofKazhdan.pdf",
3,
""
]

on@GetHierarchy[doc,4, hier]; hier

on@NavigateTo[doc, "{2C2DBCEB-B999-4BA3-94D8-CDF30D8F0911}{1}{B0}"]

on@NavigateTo[doc, doc]

ImportString[hier, "XML"][[2,3,1]]

AbsoluteTime[DatePlus[FileDate["C:\\drorbn\\AcademicPensieve\\PublicNotebook\\views\\2008-11\\Random.pdf"],
$TimeZone
] 
]

OnePage2PDF[{"ID"->"{2C2DBCEB-B999-4BA3-94D8-CDF30D8F0911}{1}{B0}","name"->"CMO 2007","dateTime"->"2008-11-19T22:29:45.000Z","lastModifiedTime"->"2008-11-19T22:30:09.000Z"}, PDFDirectory]

% // FullForm

DateList[{"2008-11-19T22:29:45.000Z", {"Year", "-", "Month", "-", "Day", "T", "Hour", ":", "Minute", ":", "Second", ".000Z"}}]

DateList["2008-11-19T22:29:45.000Z"]

AbsoluteTime["2008-11-19T22:29:45.000Z"]

PageDescriptors

$TimeZone