---
title: PowerShellでOutlookメールの内容を自動取得！
url: 'https://automationse.net/powershell-outlook-email-export'
markdown: 'https://automationse.net/powershell-outlook-email-export.md'
date: '2025-04-17'
description: 'Outlook で毎日届くメールの中から「特定のキーワードのメールを抽出したい」「添付ファイルだけ自動保存したい」と思ったことはありませんか？ この記事では、PowerShell を使って Outlook の受信メールから以下の情報を自動取得する方法をご紹介します。 件名 本文 差出人 添付ファイル名 PowerShell +…'
taxonomy:
  category:
    - IT関連
  tag:
    - PowerShell
---

# PowerShellでOutlookメールの内容を自動取得！

## [PowerShellでOutlookメールの内容を自動取得！](https://automationse.net/powershell-outlook-email-export)

  公開日 2025.04.17 更新日 2025.04.17  [PowerShell](https://automationse.net/tag:PowerShell#body-wrapper)  

 Outlook で毎日届くメールの中から「特定のキーワードのメールを抽出したい」「添付ファイルだけ自動保存したい」と思ったことはありませんか？ この記事では、PowerShell を使って Outlook の受信メールから以下の情報を自動取得する方法をご紹介します。

- 件名
- 本文
- 差出人
- 添付ファイル名

## PowerShell + Outlook の前提条件

この方法は以下の環境で動作します：

- Windows PC
- Microsoft Outlook（M365 / Office 2019など）
- PowerShell（バージョン5以上推奨）

※ Outlook はローカルにインストールされている必要があります。

## メール情報を取得してテキストファイルに出力するスクリプト

以下のスクリプトでは、件名に「請求書」が含まれるメールを対象に、件名・差出人・本文（先頭100文字）・添付ファイル名を取得し、テキストファイルに保存します。

## 出力結果の例

## まとめ

PowerShell を使えば、Outlook のルーチンワークを自動化することができます。 キーワードでの絞り込みや添付ファイルの保存を組み合わせれば、請求書処理や日報収集の自動化にも活用できます。 自動化できることはどんどん任せて、業務効率をアップしましょう！

 [ Previous Post](https://automationse.net/powershell-search-viewer) [Next Post ](https://automationse.net/android-beta-esim-issue-fix)

---

## Navigation

- Parent: [WordPress Import](https://automationse.net/wordpress-import.md)
- Previous: [Androidベータ版アップデート後にeSIMが使えなくなったときの対処法](https://automationse.net/android-beta-esim-issue-fix.md)
- Next: [PowerShellで検索する時代へ！軽量ビューアを5分で自作してみた](https://automationse.net/powershell-search-viewer.md)
