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

画像ヘッダーまたはフッターを追加する Excel で n8n

画像ヘッダー/フッターを追加 は PDF4me Excel オペレーション n8n .xlsx ワークブックのヘッダーまたはフッターにロゴやブランド画像を挿入し、1 つのワークシートまたはすべてのワークシートの左、中央、または右に配置します。これを使用すると、ファイルを開かずに生成されたレポートに一貫した企業ブランディングを適用できます。 Excel。

このノードの機能

PDF4me Excel画像ヘッダー/フッターを追加する ソースとなるワークブックと別の画像入力を受け取り、選択した水平位置でページヘッダーまたはフッターに画像を配置します。ページ余白は設定可能です。ターゲットワークシートは、名前で指定した特定のシートに画像を適用するか、空白のままにするとワークブック全体に画像を適用します。

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

認証 API リクエスト​

毎 PDF4me ノード n8n 有効な 接続するための認証情報作成または選択して、 PDF4me API ワークフローがブランディング要求を安全に認証できるようにするためのキー。

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

2つの別々の入力:ワークブックと画像
Excel ファイル入力方法と画像入力方法はそれぞれ独立して設定され、それぞれに独自のバイナリデータプロパティ名が割り当てられるため、ロゴはワークブック自体とは異なる上流ノードから取得できます。
1 つのトグルでヘッダーまたはフッターのどちらか一方を選択でき、両方を選択することはできません。
「ヘッダーまたはフッターに適用」を選択すると、実行ごとに画像が1箇所に配置されます。ヘッダーにロゴを配置し、フッターに別のマークを配置するには、2回のノード実行が必要です。
マージンのデフォルト値は Excel標準1.9cm
上、下、左、右の余白はすべてデフォルトで1.9センチメートルに設定されています。 Excelデフォルトのページ余白が設定されているため、ほとんどのワークブックでは余白を変更する必要は全くありません。
n8n の PDF4me Excel ノードを操作「画像ヘッダー/フッターの追加」に設定し、Excel ファイル入力方法と画像入力方法の両方を「前のノードから (バイナリ データ)」に設定し、バイナリ データ プロパティ名を data、画像バイナリ データ プロパティ名を image、適用先を「ヘッダーまたはフッター」に設定し、画像の位置を中央に設定し、対象ワークシートを Sheet1、上、下、左、右の余白を 1.9、出力ファイル名を excel_with_image_header_footer.xlsx に設定します。

PDF4me Excel 画像ヘッダー/フッターパラメータパネルを追加する n8n

画像ヘッダー/フッターを追加するには、どのようなパラメータが必要ですか?​

必須: 手術、 Excel ファイル入力方法、画像入力方法、両方の方法に一致する入力フィールド、および出力ファイル名。ヘッダーまたはフッターへの適用、画像の位置、対象ワークシート、および4つの余白フィールドには、すべて動作するデフォルト値が付属しています。

パラメータ必須その機能例
OperationRequiredSelects the PDF4me Excel action to run. Choose Add Image Header/Footer.Add Image Header/Footer
Excel File Input MethodRequiredHow the workbook reaches the node. From Previous Node (Binary Data) reads it from an upstream item; the dropdown also offers base64 and file URL alternatives.From Previous Node (Binary Data)
Binary Data Property NameConditionalName of the binary property on the incoming n8n item holding the .xlsx workbook. Applies when the input method is binary data. Defaults to data.data
Image Input MethodRequiredHow the image reaches the node, chosen independently of the workbook input. Supports Binary Data, Base64 String, or URL.From Previous Node (Binary Data)
Image Binary Data Property NameConditionalName of the binary property on the incoming n8n item holding the image file. Applies when Image Input Method is binary data.image
Apply to Header or FooterOptionalToggle that places the image in the header when on, or the footer when off. Default true (header).true
Image PositionOptionalHorizontal placement of the image. Left, Center, or Right. Default Center.Center
Target WorksheetsOptionalComma-separated worksheet names to apply the image to. Leave blank to apply it to every worksheet.Sheet1
Top MarginOptionalTop page margin in centimeters. Default 1.9.1.9
Bottom MarginOptionalBottom page margin in centimeters. Default 1.9.1.9
Left MarginOptionalLeft page margin in centimeters. Default 1.9.1.9
Right MarginOptionalRight page margin in centimeters. Default 1.9.1.9
Output File NameRequiredFilename for the branded workbook the node returns. Include the .xlsx extension.excel_with_image_header_footer.xlsx

出力フィールド​

成功したランは1 n8n 持ち運んでいるアイテム JSON メタデータと、ブランド化されたワークブックをバイナリデータとして含む。

分野タイプ内容物
successBooleanTrue when the image was applied successfully. Use it to route error-handling branches.
fileNameStringFilename of the branded workbook, matching Output File Name.
fileSizeNumberSize of the returned workbook in bytes.
originalFileNameStringThe filename of the input workbook, echoed back for tracking.
isHeaderBooleanTrue when the image was placed in the header, false when placed in the footer.
positionStringHorizontal alignment applied to the image: Left, Center, or Right.
worksheetNamesArrayWorksheet names the image was applied to.
topMarginNumberTop page margin in centimeters, matching the Top Margin input.
bottomMarginNumberBottom page margin in centimeters, matching the Bottom Margin input.
leftMarginNumberLeft page margin in centimeters, matching the Left Margin input.
rightMarginNumberRight page margin in centimeters, matching the Right Margin input.
messageStringHuman-readable result message for the operation.
Binary (data)BinaryThe branded .xlsx workbook. Pass into Write Binary File, Email, or a cloud-storage upload.

N8N 行動対応​

JSON 回答形式

[
{
"fileName": "excel_with_image_header_footer.xlsx",
"fileSize": 221849,
"success": true,
"originalFileName": "myExcelFile.xlsx",
"isHeader": true,
"position": "Center",
"worksheetNames": ["Sheet1"],
"topMargin": 1.9,
"bottomMargin": 1.9,
"leftMargin": 1.9,
"rightMargin": 1.9,
"message": "Image header/footer added to Excel file successfully"
}
]

画像ヘッダー/フッターの設定方法 n8n?​

  1. 追加する PDF4me Excel ノードをワークフローに追加して設定します 手術 に 画像ヘッダー/フッターを追加。
  2. で 接続するための認証情報選択してください PDF4me API 認証情報を使用するか、またはあなたの API 鍵。
  3. セット Excel ファイル入力方法 そして バイナリデータプロパティ名 ソースワークブック用。
  4. セット 画像入力方法 そして 画像バイナリデータプロパティ名 ロゴや画像用。
  5. スイッチ ヘッダーまたはフッターに適用する ヘッダー画像の場合はオン、フッター画像の場合はオフに設定します。
  6. セット 画像の位置 に 左、 中心、 または 右。
  7. セット 目標ワークシートまたは、空白のままにして画像全体を適用し、必要に応じて余白を調整してください。
  8. セット 出力ファイル名 で終わる .xlsxノードを実行し、ブランド化されたワークブックを次の処理にルーティングします。

典型的な構成​

ワークフローの例Common n8n workflow patterns using Add Image Header/Footer for Excel.
生成されたすべてのレポートに会社のロゴが表示されます
  1. スケジュールトリガーは、週ごとの数値ワークブックを作成します。
  2. 画像ヘッダー/フッターを追加すると、ヘッダーまたはフッターに適用、画像の位置を右に設定して、会社のロゴが挿入されます。
  3. ブランドロゴ入りのレポートは、関係者にメールで送信されます。
納品物へのクライアントとの共同ブランディング
  1. ワークフローがクライアントのロゴを取得します URL から CRM 記録。
  2. 画像入力方法は次のように設定されています。 URL つまり、ロゴはそのレコードから直接読み込まれるということです。
  3. ワークブックのヘッダーには、クライアント独自のブランドロゴが入っています。
フッターに承認印
  1. マネージャーが社内ツールで承認すると、承認用ウェブフックが起動します。
  2. 画像ヘッダー/フッターの追加機能は、「ヘッダーまたはフッターに適用」をオフにした状態で実行され、承認グラフィックをフッターに配置します。
  3. スタンプが押されたワークブックはアーカイブされます SharePoint。
概要シートのみにブランドを付ける
  1. 複数シートのワークブックには、生データタブと要約シートが含まれています。
  2. ターゲットワークシートは「概要」に設定されているため、生データタブにはブランド表示はされません。
  3. ブランド化された要約シートは、 PDF 配布用。

実践的なヒント​

Header and footer need separate runs
Apply to Header or Footer only picks one location per execution. Add a second node for the other placement.
Image and workbook inputs are independent
Image Input Method does not have to match Excel File Input Method. A logo can come from a public URL while the workbook comes from binary data.
Target Worksheets is comma-separated
List multiple sheet names like Sheet1,Summary to brand several sheets at once, or leave it blank for the whole workbook.
Margins are in centimeters, not inches
The 1.9 default matches Excel's standard margin in centimeters. Adjust with that unit in mind when nudging image placement.
Output File Name needs the .xlsx extension
Omitting it can leave downstream nodes unable to detect the format when writing or emailing the file.
Use a transparent PNG for a cleaner look
A transparent-background logo blends into the page better than a solid rectangle, especially over shaded header rows.

チートシート​

分野価値
OperationAdd Image Header/Footer
Excel File Input MethodFrom Previous Node (Binary Data)
Binary Data Property Namedata
Image Input MethodFrom Previous Node (Binary Data)
Image Binary Data Property Nameimage
Apply to Header or Footeron (header)
Image PositionCenter
Target WorksheetsSheet1 (blank for all)
Top / Bottom / Left / Right Margin1.9 cm each
Output File Nameexcel_with_image_header_footer.xlsx
CredentialsPDF4me API credential

よくある質問​

Does the toggle add the image to the header or the footer?+
Apply to Header or Footer is a single toggle that switches placement between the two. Switched on, the image goes into the header; switched off, it goes into the footer. The response echoes the placement back as isHeader true or false.
What happens if Target Worksheets is left empty?+
The image is applied to every worksheet in the workbook. Entering one or more comma-separated sheet names restricts the image to those sheets only, and the response lists them back in worksheetNames.
Can I place a logo in the header and a different image in the footer?+
Yes, but not in one execution. Run the Add Image Header/Footer operation twice in the same workflow, once with Apply to Header or Footer switched on for the header image and once switched off for the footer image.
What units are the margin fields in?+
Top Margin, Bottom Margin, Left Margin, and Right Margin are all in centimeters and default to 1.9, matching Excel's standard page margin. Increase a margin to push the image further from the page edge.
Which image formats does Image Input Method accept?+
Common raster formats such as PNG, JPG, JPEG, and GIF are supported, supplied through Binary Data, a Base64 String, or a public URL, the same input pattern used throughout n8n's integrations for binary data.

関連アクション​

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

ヘルプが必要な場合​