IWMPStringCollection2::getAttributeCountByType method

The getAttributeCountByType method returns the number of attributes associated with the specified string collection index, attribute name, and language.


public System.Int32 getAttributeCountByType(
  System.Int32 lCollectionIndex,
  System.String bstrType,
  System.String bstrLanguage

Public Function getAttributeCountByType( _
  ByVal lCollectionIndex As System.Int32, _
  ByVal bstrType As System.String, _
  ByVal bstrLanguage As System.String _
) As System.Int32
Implements IWMPStringCollection2.getAttributeCountByType


lCollectionIndex [in]

The System.Int32 specifying the zero-based index of the string collection item from which to get the attribute.

bstrType [in]

The System.String that is the name of the attribute.

bstrLanguage [in]

The System.String that is the name of the language. If the value is set to null or to a zero-length string (""), the current locale string is used. Otherwise, the value must be a valid RFC 1766 language string such as "en-us".

Return value

The System.Int32 that is the count.


This method is used to discover the number of attributes corresponding to a particular attribute name for a given StringCollection item. Index numbers can then be passed to the fourth parameter of the getItemInfoByType method.

To use this method, read access to the library is required. For more information, see Library Access.


Windows Media Player 11.
Interop.WMPLib.dll (Interop.WMPLib.dll.dll)

See also

IWMPStringCollection2 Interface (VB and C#)

IWMPStringCollection2.getItemInfoByType (VB and C#)