Skip to content

Latest commit

 

History

History
50 lines (39 loc) · 2.62 KB

File metadata and controls

50 lines (39 loc) · 2.62 KB
title IAppHostPropertyCollection::Item Property
description Describes the IAppHostPropertyCollection::Item property and details its syntax, parameters, return value, code example, and requirements.
ms.date 10/07/2016
ms.assetid 5e7303e8-480b-dbd5-a48b-8435540f2ab2

IAppHostPropertyCollection::Item Property

Gets the property with the requested index or property name in the collection.

Syntax

HRESULT get_Item(  
   [in] VARIANT cIndex,  
   [out,  
   retval] IAppHostProperty** ppProperty  
);  

Parameters

cIndex
A VARIANT that contains the index or property name of the item to retrieve from the collection.

ppProperty
A pointer to a pointer for an IAppHostProperty interface.

Return Value

An HRESULT. Possible values include, but are not limited to, those in the following table.

Value Description
S_OK Indicates that the operation was successful.
ERROR_INVALID_INDEX Indicates that the requested property was not found.

Example

The following code example demonstrates how to use the IAppHostPropertyCollection interface to access the enabled property of the defaultDocument configuration section.

[!code-cppIAppHostAdminLibrary#6]

Requirements

Type Description
Client - IIS 7.0 on [!INCLUDEwinvista]
- IIS 7.5 on Windows 7
- IIS 8.0 on Windows 8
- IIS 10.0 on Windows 10
Server - IIS 7.0 on [!INCLUDEwinsrv2008]
- IIS 7.5 on Windows Server 2008 R2
- IIS 8.0 on Windows Server 2012
- IIS 8.5 on Windows Server 2012 R2
- IIS 10.0 on Windows Server 2016
Product - IIS 7.0, IIS 7.5, IIS 8.0, IIS 8.5, IIS 10.0
- [!INCLUDEiisexp75], [!INCLUDEiisexp80], [!INCLUDEiisexp100]
Header Ahadmin.h

See Also

IAppHostPropertyCollection Interface