MsiRecordSetInteger 関数 (msiquery.h)

MsiRecordSetInteger 関数は、レコード フィールドを整数フィールドに設定します。

構文

UINT MsiRecordSetInteger(
  [in] MSIHANDLE hRecord,
  [in] UINT      iField,
  [in] int       iValue
);

パラメーター

[in] hRecord

レコードへのハンドル。

[in] iField

設定するレコードのフィールドを指定します。

[in] iValue

フィールドを設定する値を指定します。

戻り値

この関数は UINT を返します。

注釈

MsiRecordSetInteger 関数で、存在しないフィールドに値を格納しようとするとエラーが発生します。 次のコードは ERROR_INVALID_PARAMETERを返します。

MSIHANDLE hRecord;
UINT lReturn;  

//create an msirecord with no fields
hRecord = MsiCreateRecord(0); 

//attempting to set the first field's value gives you ERROR_INVALID_PARAMETER 
lReturn = MsiRecordSetInteger(hRecord, 1, 0);  

レコード整数フィールドを NULL_INTEGERに設定するには、 iValueMSI_NULL_INTEGER に設定します。

要件

要件
サポートされている最小のクライアント Windows Server 2012、Windows 8、Windows Server 2008 R2、または Windows 7 の Windows インストーラー 5.0。 Windows Server 2008 または Windows Vista の Windows インストーラー 4.0 または Windows インストーラー 4.5。
対象プラットフォーム Windows
ヘッダー msiquery.h
Library Msi.lib
[DLL] Msi.dll

こちらもご覧ください

レコード処理関数