Export (0) Print
Expand All
Expand Minimize

SetupFindFirstLine Function

[This function is available for use in the operating systems indicated in the Requirements section. It may be altered or unavailable in subsequent versions. SetupAPI should no longer be used for installing applications. Instead, use the Windows Installer for developing application installers. SetupAPI continues to be used for installing device drivers.]

The SetupFindFirstLine function locates a line in the specified section of an INF file. If the Key parameter is NULL, SetupFindFirstLine returns the first line of the section.

Syntax

BOOL SetupFindFirstLine(
  __in     HINF InfHandle,
  __in     PCTSTR Section,
  __in     PCTSTR Key,
  __inout  PINFCONTEXT Context
);

Parameters

InfHandle [in]

Handle to the INF file to query.

Section [in]

Pointer to a null-terminated string specifying the section of the INF files to search in.

Key [in]

Optional pointer to a null-terminated string specifying the key to search for within the section. The null-terminated string should not exceed the size of the destination buffer. This parameter can be NULL. If Key is NULL, the first line in the section is returned.

Context [in, out]

Pointer to a structure that receives the context information used internally by the INF handle. Applications must not overwrite values in this structure.

Return Value

If the function could not find a line, the return value is zero. To get extended error information, call GetLastError.

Remarks

If the InfHandle parameter references multiple INF files that have been appended together using SetupOpenAppendInfFile, the SetupFindFirstLine function searches across the specified section in all of the files referenced by the specified HINF.

Requirements

Minimum supported client

Windows 2000 Professional

Minimum supported server

Windows 2000 Server

Header

Setupapi.h

Library

Setupapi.lib

DLL

Setupapi.dll

Unicode and ANSI names

SetupFindFirstLineW (Unicode) and SetupFindFirstLineA (ANSI)

See Also

Overview
Functions
SetupFindNextLine
SetupFindNextMatchLine
SetupGetLineByIndex

 

 

Build date: 8/19/2010

Community Additions

ADD
Show:
© 2014 Microsoft