MsiRecordGetFieldCount Function

Windows Installer

MsiRecordGetFieldCount Function

The MsiRecordGetFieldCount function returns the number of fields in a record.

Syntax

C++unsigned int MsiRecordGetFieldCount(
  __in  MSIHANDLE hRecord
);

Parameters

hRecord [in]

Handle to a record.

Return Value

If the function succeeds, the return value is the number of fields in the record.

If the function is given an invalid or inactive handle, it returns -1 or 0xFFFFFFFF.

Remarks

The count returned by the MsiRecordGetFieldCount parameter does not include field 0. Read access to fields beyond this count returns null values. Write access fails.

Requirements

VersionWindows Installer 5.0 on Windows Server 2008 R2 or Windows 7. Windows Installer 4.0 or Windows Installer 4.5 on Windows Server 2008 or Windows Vista. Windows Installer on Windows Server 2003, Windows XP, and Windows 2000
HeaderMsiquery.h
LibraryMsi.lib
DLLMsi.dll

See Also

Record Processing Functions

Send comments about this topic to Microsoft

Build date: 8/13/2009

© 2009 Microsoft Corporation. All rights reserved.