Shell Scrap Object (.shs):Windows 95/98/XP 時代的「剪貼簿殘片」格式。使用者將 Word/Excel 內容**拖曳到桌面/資料夾**時產生,內含 **OLE 內嵌物件** (文字、圖片、表格、公式)。**非純文字檔,無法直接用記事本完整閱讀**。
.doc 或 .txt。Windows Vista 後已棄用 .shs,改用「剪貼簿歷程記錄」(Win+V) 與「OneNote/便箋/白板」管理片段資料。建議將舊 .shs 批次轉存為 .docx/.pdf 歸檔。
$word = New-Object -ComObject Word.Application
$word.Visible = $false
Get-ChildItem -Path "D:\OldScraps" -Filter "*.shs" | ForEach-Object {
$doc = $word.Documents.Open($_.FullName)
$newName = $_.FullName -replace '\.shs$', '.docx'
$doc.SaveAs([ref]$newName, [ref]16) # 16 = wdFormatXMLDocument
$doc.Close()
}
$word.Quit()
※ 需安裝 Word,且 .shs 必須為 Word 來源才能完美轉換。