---
sourceDocument: Xanadu API リファレンス
sourceDocumentLink: https://www.servicenow.com/docs/r/ja-JP/xanadu/api-reference

 Release :

    - xanadu

ft:locale :

    - ja-JP

ft:publication_title :

    - Xanadu API リファレンス

ft:clusterId :

    - crapiref

bundleId :

    - crapiref

workflow :

    - Creator


---

# TemplatePrinter - スコープ指定

# TemplatePrinter - スコープ指定 {#ariaid-title1}

* リリースバージョン: Xanadu
* 
* 更新日 2024年08月01日
* 
* ![](https://www.servicenow.com/docs/portal-asset/ico-clock) 所要時間：1分

TemplatePrinter API は、メールスクリプトからメールメッセージへの出力を処理するメソッドを提供します。

この API のコンストラクタはありません。メソッドは、メールスクリプト内でグローバル変数 template を使用して呼び出されます。

## TemplatePrinter - print(文字列、文字列) {#ariaid-title2}

メール本文に文字列を出力します。
{#r_TPS-print_S__table_cnv_rdy_nt__entry__3}

| 名前 | タイプ | 説明 |
|-|-|-|
| string | 文字列 | 出力する文字列。 |
[表 : 1. パラメーター]

{#r_TPS-print_S__table_cnv_rdy_nt} {#r_TPS-print_S__table_dnv_rdy_nt__entry__2}

| タイプ | 説明 |
|-|-|
| なし |   |
[表 : 2. 返される内容]

{#r_TPS-print_S__table_dnv_rdy_nt}  

    template.print("Incident number - " + current.number + "\n");

## TemplatePrinter - space(番号スペース) {#ariaid-title3}

メール本文に改行なしのスペースを追加します。
{#r_TPS-space_N__table_pys_c2y_nt__entry__3}

| 名前 | タイプ | 説明 |
|-|-|-|
| spaces | 番号 | メール本文に出力する改行なしスペースの数。 |
[表 : 3. パラメーター]

{#r_TPS-space_N__table_pys_c2y_nt} {#r_TPS-space_N__table_qys_c2y_nt__entry__2}

| タイプ | 説明 |
|-|-|
| なし |   |
[表 : 4. 返される内容]

{#r_TPS-space_N__table_qys_c2y_nt}  

    template.space(4);


