メインコンテンツへスキップ

ワークシートを削除する Excel 使用 Zapier

ワークシートを削除する は Zapier アクション PDF4me 不要なシートを取り除く Excel ワークシート名、ワークシートインデックス、またはその両方を結合ロジックと組み合わせてワークブックを作成します。組み込みの安全機能により、常に少なくとも1つのワークシートが保持されるため、誤った選択によってワークブックが空になることはありません。この機能をトリガーして、配布前にテンプレートからサンプルシートを削除したり、内部計算タブを削除したりできます。

関連ブログ記事
この機能に関するブログ記事はまだありません。近日公開予定です。
その間、PDF4me ブログを閲覧して、あらゆるプラットフォームのチュートリアルやワークフローをご覧ください。
ブログをご覧ください →

認証方法 API リクエスト?​

アクセスするには PDF4me ウェブ API を通して Zapierすべてのリクエストには適切な認証情報を含める必要があります。認証により安全な通信が保証され、承認されたユーザーとしての身元が検証され、シームレスな統合が可能になります。 Zapier ワークフローと PDF4meの Excel ワークシート管理サービス。

PDF4me Excel ワークシート削除 Zapier 設定 - ファイル、ファイル名 add_header_sample_file.xlsx、ワークシート名 Sheet1、Sheet2、ワークシートインデックス
ワークシート削除アクションを設定します。ファイルとファイル名をマッピングし、ワークシート名またはワークシートインデックスを使用してシートをターゲットにします。

見逃してはならない重要な事実​

必要なのはファイルのみです
スクリーンショットから、アスタリスクが付いているフィールドは「ファイル」のみであることが確認できます。ファイル名、ワークシート名、ワークシートインデックスはすべてオプションです。 Zapier UI。
少なくとも1枚のワークシートは必ず残る
組み込みの安全チェック機能により、選択した操作でワークブック内のすべてのワークシートが削除される場合でも、実際には削除されないようになっています。
名前とインデックスは、ユニオンロジックと組み合わされます。
ワークシート名とワークシートインデックスの両方を使用すると、どちらか一方に一致するすべてのシートが削除され、重複する一致は適切に処理されます。

設定概要​

設定例 Zapier インターフェース

スクリーンショットには、前の手順でマッピングされたファイルが表示されています。ファイル名は「add_header_sample_file.xlsx」、ワークシート名は「Sheet1,Sheet2」に設定され、ワークシートインデックスは空欄になっています。

ファイル名

add_header_sample_file.xlsx

ワークシート名

シート1、シート2

ワークシート索引

オプション(1ベース)

:::ヒント:前の手順でマップファイルとファイル名を取得してください + 隣のボタン ファイル そして ファイル名 以前の Zap ステップからマッピングするには、たとえば、 ファイル名全体 以前の PDF4me Excel 行動。 Excelファイルには完全なコンテンツを提供する必要があり、「存在するが表示されない」参照は認められません。 :::

:::警告 ファイル: (存在しますが表示されません) ファイルフィールドに「ファイル: (存在しますが表示されません)」と表示され、「ファイルが空です」エラーが発生する場合は、 ファイルの内容全体 代わりに。参照 Zapier & Power Automate ヒント詳細は :::

パラメータ​

ワークシート削除アクションのパラメーターの完全なリスト。パラメーター名は、 Zapier 構成 UI。

必須 Zapier UI: ファイルのみ。ファイル名、ワークシート名、ワークシートインデックスはすべてオプションですが、何かを削除するには、ワークシート名またはワークシートインデックスのいずれか少なくとも1つが必要です。

パラメータ必須その機能例
FileOptionalExcel file content, mapped from a previous step using full file content.[2. File from Step 2]
File NameOptionalFilename with .xlsx or .xls extension, used for output naming.add_header_sample_file.xlsx
Worksheet NamesOptionalComma-separated, case-sensitive list of worksheet names to delete. Combines with Worksheet Indexes via union logic.Sheet1,Sheet2
Worksheet IndexesOptionalComma-separated, 1-based list of worksheet positions to delete. Combines with Worksheet Names via union logic.1,3
File URL (Either provide File or File URL)OptionalLink to the Excel workbook to delete the worksheets from, as an alternative to File. Map a file URL from a previous step.
File NameOptionalName of the Excel file, including its extension (for example `report.xlsx`).
名前とインデックスの両方を使用する場合のユニオンロジック

両方を指定する場合 ワークシート名 そして ワークシート索引この操作では、両方のセットの和集合が削除されます。たとえば、「Sheet1,Sheet2」と「3」を選択すると、Sheet1、Sheet2、および3番目のワークシートが削除されます。重複した選択(名前とインデックスの両方で識別される同じシート)も適切に処理されます。

出力にはどのようなフィールドが含まれますか?​

このアクションは変更された Excel ファイルとトラッキングメタデータ。この出力形状は、 PDF4me Excel アクション Zapier ファイルを返すもの。

分野タイプ内容物
jobIdTextID of the PDF4me job that processed the request.
traceIdTextTrace ID of the request, when PDF4me returns one. Give it to PDF4me support when reporting a problem.
documentIdTextID PDF4me gives the resulting document.
File NameTextName of the resulting file, without extension.
File ExtensionTextExtension of the resulting file, for example `.pdf`.
Full File NameTextName of the resulting file, with extension.
File UrlTextDownload link of the resulting file. Map it into any later step that needs the file, for example an upload to Google Drive, Dropbox or OneDrive.
Alternate File UrlTextAlternative download link of the resulting file, with the file name at the end of the URL.
File SizeNumberSize of the resulting file, as reported by PDF4me.

典型的な構成​

ワークフローの例Common Zapier workflow patterns using Delete Worksheets.
配布されたテンプレートからサンプルシートを抜き取る
  1. マスターテンプレートがコンテンツライブラリ内で配布準備完了とマークされると、トリガーが作動します。
  2. 「ワークシートの削除」コマンドは、ワークシート名をサンプルシート名と手順シート名に設定して実行され、作業中のシートはそのまま残ります。
  3. クリーニング済みのテンプレートは、共有テンプレートライブラリにアップロードされます。
役員への配布前に内部計算シートを取り除いてください。
  1. 週次経営報告書が複数の計算シートとともに生成され、Zapがトリガーされる。
  2. 「ワークシートの削除」コマンドは、内部計算シートの位置にワークシートインデックスを設定した状態で実行され、プレゼンテーションシートは保持されます。
  3. 最終報告書は経営陣にメールで送信されます。
ローリングレポートから古い月を削除する
  1. 月次メンテナンス トリガーが起動し、次の場所から取得したローリング 12 か月 レポートを削除します。 SharePoint。
  2. 「ワークシートの削除」処理は、保持期間を過ぎた月のシートを一覧表示するために動的に構築されたワークシート名を使用して実行されます。
  3. トリミングされたローリングレポートは、 SharePoint。

実践的なヒント​

Map full file content, not a reference
If File shows "Exists but not shown", pick the mapping option that provides full file content, or the action can fail with a file-is-empty error.
Worksheet name matching is case-sensitive
Worksheet Names must match the exact sheet name, including case, or the sheet will not be found for deletion.
Combine Names and Indexes for mixed selections
Set both Worksheet Names and Worksheet Indexes in the same run to delete a union of specific sheets by name and by position.
One worksheet always survives
The action will not let you delete every sheet in the workbook, even if your combined selection would otherwise remove all of them.
Worksheet Indexes starts at 1, not 0
1 refers to the first worksheet in the workbook. Double-check sheet order before building a dynamic index list.

チートシート​

分野価値
ActionDelete Worksheets
File[mapped from previous step, full content]
File Nameadd_header_sample_file.xlsx
Worksheet NamesSheet1,Sheet2
Worksheet Indexes1,3 (alternative or combined)

よくある質問​

How do I delete a worksheet in Excel automatically using Zapier?+
Add the PDF4me Delete Worksheets action to a Zap, map File with full file content, set Worksheet Names and/or Worksheet Indexes for the sheets you want removed, and run the Zap. See Microsoft's Worksheet.Delete method reference for how the same removal works at the VBA level.
What happens if I use both Worksheet Names and Worksheet Indexes?+
The action deletes the union of both sets. For example, Worksheet Names of Sheet1,Sheet2 combined with Worksheet Indexes of 3 deletes Sheet1, Sheet2, and the third worksheet, with duplicate selections handled gracefully.
Can I delete every worksheet in the workbook?+
No. The action includes a safety check that always preserves at least one worksheet, even if your Worksheet Names and Worksheet Indexes selections would otherwise remove everything.
Is worksheet name matching case-sensitive?+
Yes. Worksheet Names requires an exact, case-sensitive match to the sheet name in the workbook, so Sheet1 and sheet1 are treated as different names.
Are worksheet indexes 1-based or 0-based?+
Worksheet Indexes is 1-based, so index 1 refers to the first worksheet in the workbook, index 2 to the second, and so on. See this Microsoft Tech Community discussion on worksheet deletion issues for common manual deletion problems this action avoids.

関連アクション​

他のプラットフォームでの同じタスク​

業界におけるユースケースとアプリケーション​

  • クライアントレポートの最終化: 顧客の財務報告書から内部計算および仮定ワークシートを削除する
  • 予算テンプレートの整理: 新しい会計年度の予算テンプレートから前年度のワークシートを削除します
  • 監査ファイルの準備監査ファイルのアーカイブ前に、下書きと作業用紙のワークシートを削除してください。
  • ローリング予測メンテナンス: 12か月ローリング予測ワークブックから不要になった月のワークシートを削除します
  • 統合クリーンアップ統合シート作成後、個々のエンティティのワークシートを削除します。

ヘルプが必要な場合​