loop over every notebook
This commit is contained in:
@@ -1,6 +1,3 @@
|
||||
|
||||
|
||||
|
||||
# Get export folder
|
||||
$folder = "C:\Users\pgeeraert\Downloads\export-onenote"
|
||||
|
||||
@@ -26,13 +23,13 @@ function LoopAndExport {
|
||||
foreach ($notebook in $Hierarchy.Notebooks.Notebook ) {
|
||||
$name = ReplaceIllegal -text $notebook.name
|
||||
|
||||
if($name -ccontains "Deployments"){
|
||||
|
||||
Write-Output $name
|
||||
Write-Host $notebook.ID
|
||||
Write-Host $notebook.InnerXml
|
||||
|
||||
|
||||
$destinationFile = Join-Path -Path $folder -ChildPath $name".test.xml"
|
||||
$destinationFile = Join-Path -Path $folder -ChildPath $name".xml"
|
||||
|
||||
write-output $destinationFile
|
||||
|
||||
@@ -41,7 +38,7 @@ function LoopAndExport {
|
||||
$exportedXML = "<xml>$notebookInnerXml</xml>"
|
||||
|
||||
$exportedXML |Out-File $destinationFile
|
||||
}else{}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user