CSV(カンマ区切り値)ファイルは、値を特定の文字で区切ったテキストファイルです。Power Automateでは、Launch Excelアクションを使用して、カンマ区切りおよびタブ区切りのCSVファイルを直接開けます。Excelでは、Windowsの地域設定で定義されたリスト区切り文字が使用され、地域によってはセミコロンを手動で設定する必要があります。CSVファイルからの読み取りアクションを使用し、セミコロンをカスタム区切り文字に設定することで、セミコロン区切りのCSVファイルに対応できます。
Power AutomateでのCSVファイルのExcelへの変換
CSV(カンマ区切り値)ファイルとは、特定の区切り文字を使用して一連の値を分離する区切り付きテキストファイルです。Power Automateを使用すると、カンマ区切りおよびタブ区切りのCSVファイルを直接「Excelを起動」アクションを通じて開くことができます。
注意事項
- Excelでは、Windowsの地域設定で定義されたリスト区切り文字を使用します。一部の地域では、区切り文字としてセミコロン(;)を手動で設定する必要があるか、次の回避策を適用する必要があります。
「Excelを起動」アクションの実行方法
- Power Automate デスクトップを開く。
- 編集する既存のフローを開くか、新しいフローを選択して新しいフローを作成します。
- フローデザイナーの左側のアクションペインで、Excelを展開し、Excelを起動をダブルクリックします。
- 必要なパラメーターを入力し、保存を選択します。
次に、Excelを起動アクションを使用して空のExcelドキュメントを起動し、Excelワークシートに書き込むアクションを使用してCSVテーブルをセルA1に貼り付けます。
その後、Excelを閉じるアクションを展開して、新しいXLSXファイルとしてExcelワークシートを保存できます。このためには、文書を名前を付けて保存を選択し、文書形式にExcelブック(.xlsx)を選択します。
セミコロン区切りのCSVファイル
「Excelを起動」アクションは、前述したケースを処理できますが、セミコロン区切りのCSVファイルには別のアプローチが必要かもしれません。
この制限を克服するために、CSVファイルから読み取るアクションを使用し、セミコロン(;)をカスタム区切り文字として設定します。CSVファイルの最初の行にヘッダーが含まれている場合は、最初の行が列名を含むオプションを有効にして、取得したデータテーブルでそれぞれのヘッダーを使用します。
参考リンク
このガイドをもとに、Power Automateを使用してCSVファイルをExcelに効率的に変換する方法を学び、ビジネスプロセスの自動化に役立ててください。
————-
Convert a CSV file into an Excel spreadsheet – Power Automate
Source link
The article discusses how to work with CSV files in Power Automate using the Launch Excel action. It explains that a CSV file is a text file that uses specific characters to separate values. Power Automate allows users to open these files directly. Depending on regional settings in Windows, users may need to set a semicolon as the separator manually, especially for semicolon-delimited CSV files.
To use the Launch Excel action, users should open Power Automate desktop and either edit an existing flow or create a new one. They can then launch a blank Excel document and paste the CSV data into it. The next step is to save the document in the XLSX format using the Close Excel action.
For semicolon-delimited CSV files, users need to employ the Read from CSV file action, setting the semicolon as a Custom separator in the advanced options. If the CSV has headers, they can opt to include these in the imported data.
The article also references the Excel actions reference for additional guidance.
コメント