> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abbyy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# AddNewEmptyDocument

> AddNewEmptyDocument Web Services API メソッドを使用して、FlexiCapture のバッチに空のドキュメントを追加し、ページをアタッチします。

<div id="what-it-does">
  ## 機能
</div>

空のドキュメントをバッチに追加します。その後、[AddNewPageEx](/ja/flexi-capture/api/methods/add-new-page-ex) メソッドを使用して、このドキュメントにページをアタッチできます。新しいドキュメントは、`excludeFromAutomaticAssembling` フラグが `true` に設定された状態で作成されます。このフラグは、そのドキュメントがすでに組み立て済みであるため、バッチタイプに指定されたアセンブリ設定がこのドキュメントには適用されないことを示します。

このメソッドは、以前のバージョンの API との互換性のために残されています。空のドキュメントを作成するには、`file` パラメーターを空のままにして (`file.Name = ""`, `file.Bytes = new bytes [0]`) 、[AddNewDocumentEx](/ja/flexi-capture/api/methods/add-new-document-ex) メソッドを使用することもできます。

<div id="definition">
  ## 定義
</div>

```csharp theme={null}
int AddNewEmptyDocument(int sessionId, int batchId);
```

<div id="parameters">
  ## パラメーター
</div>

| 名前          | 型     | 説明                         |
| ----------- | ----- | -------------------------- |
| `sessionId` | `int` | Application Server への接続 ID |
| `batchId`   | `int` | ドキュメントを追加するバッチの ID         |

<div id="returned-value">
  ## 戻り値
</div>

| 型     | 説明                |
| ----- | ----------------- |
| `int` | 作成された空のドキュメントの ID |
