> ## 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.

# FieldDefinitions オブジェクトの AddNew メソッド

このメソッドは、指定した型の新しいfield定義をコレクションの末尾に追加します。

## 構文

```vb Visual Basic .NET theme={null}
Function AddNew( _
  Type As FieldTypeEnum, _
  Name As String _
) As FieldDefinition
```

```cpp C++ theme={null}
HRESULT AddNew(
  FieldTypeEnum      Type,
  BSTR               Name,
  IFieldDefinition** Result
);
```

## パラメーター

*Type*

\[in] この変数は、field の型を指定します。[**FieldTypeEnum**](https://docs.abbyy.com/ja/flexi-capture/sdk/api-reference/fieldtypeenum.md) 定数の説明を参照してください。このパラメーターの値に使用できるのは、FT\_TextField、FT\_Checkmark、FT\_CheckmarkGroup、FT\_Table、FT\_PictureField、FT\_Group の各定数のみです。

**Name**

\[in] この変数は、field の名前を指定します。field の名前にスペースを含めることはできません。スペースが含まれていると学習できません。

**Result**

\[out, retval] 追加された field 定義のインターフェースポインターを受け取る [**IFieldDefinition**](https://docs.abbyy.com/ja/flexi-capture/sdk/api-reference/fielddefinition.md)\*\*\*\*\* 変数へのポインター。

## 戻り値

このメソッドには固有の戻り値はありません。[ABBYY FlexiCapture SDK 関数の標準戻り値](https://docs.abbyy.com/ja/flexi-capture/sdk/api-reference/errorcodes.md)を返します。

## 関連項目

[**FieldDefinitions**](https://docs.abbyy.com/ja/flexi-capture/sdk/api-reference/fielddefinitions.md)
