Skip to main content
ATL Server Library Reference 
CBrowserCapsSvc Class 

This class allows you to get access to objects that provide information about the capabilities of a particular user agent (Web browser).


class CBrowserCapsSvc :
   public IBrowserCapsSvc,
   public CComObjectRootEx< CComSingleThreadModel >

The information about a particular user agent is exposed by the IBrowserCaps interface. Pointers to objects implementing this interface are returned by the IBrowserCapsSvc::GetCaps and IBrowserCapsSvc::GetCapsUserAgent methods.

This class implements the IBrowserCapsSvc by reading information from a file named browscap.ini. This file associates user agent strings (Web browser identifiers) with information about the capabilities of those user agents. The format of this file is the same format used by the Browser Capabilites component described in Browscap.ini File.

Note that browscap.ini will be loaded from the same location as the module whose HINSTANCE is used to initialize this object if a file of that name is present. Otherwise it will be loaded from the inetsrv directory beneath the system directory (the location of the standard browscap.ini file installed by IIS). See CBrowserCapsSvc::Initialize. This method must be called before any other method in this class.

Header: atlutil.h