[This is preliminary documentation and subject to change.]
The LoadEnhancement method loads a single enhancement into the Guide database.
HRESULT LoadEnhancement(
Workspace *piDAOWorkspace,
BSTR bstrEnhancementID,
BSTR bstrShowReference,
BSTR bstrTitle,
BSTR bstrPreloadURL,
BSTR bstrAddress,
DATE dateExpire,
DWORD dwFlags
);
If the bstrShowReference parameter contains an episode title, the enhancement is treated as an episode enhancement and set for only the episode or episodes specified.
If bstrShowReference contains an empty episode title (""), the enhancement is treated as a channel enhancement. In this case, LoadEnhancement searches the tuning space for the union of the station, network, and channel parameters specified in bstrShowReference. The method then sets an enhancement for all matching channel records.
The following is an example of a episode show reference:
"1997/7/29!26673/7175/9690!0:30!0!0!0!0!9690!9690!4096!7040!''!'MSNBC'!3!54!InterNight".
For further description of show reference syntax, see Show Reference Format.
For example, if you specify "TVShow\TVShow.htm"
for the bstrPreloadURL parameter,
the URL resolves to "C:\Program Files\TV Viewer\Layouts\TVShow\TVShow.htm"
.
"NIC_address\tmulticast_address\tmulticast_port"
For example:
"125.125.125.125\t225.225.225.255\t10024"
Value | Meaning |
---|---|
LE_DONTOVERWRITE | If this flag is set, and the enhancement data already exists in the database, LoadEnhancement does not reload the data. The value of bstrEnhancementID is used to determine whether the data is already loaded in the database. |
LE_LOUD | If this flag is set, LoadEnhancement sends an operating-system broadcast message to inform applications that use this data that the data has changed. Otherwise, LoadEnhancement does not send a message. |
LE_UPDATEADDRESSFIELD | If this flag is set, LoadEnhancement updates the address data for this record in the Guide database. |
LE_UPDATEDATEFIELD | If this flag is set, LoadEnhancement updates the time and date data for this record in the Guide database. |
LE_UPDATEFIELDS | If this flag is set, LoadEnhancement updates the data for this record in the Guide database, replacing the values of all non-NULL parameters. |
LE_UPDATEPRELOADURLFIELD | If this flag is set, LoadEnhancement updates the URL of the starting enhancement page for this record in the Guide database. |
LE_UPDATESHOWREFFIELD | If this flag is set, LoadEnhancement updates the show reference data for this record in the Guide database. |
LE_UPDATETITLEFIELD | If this flag is set, LoadEnhancement updates the title data for this record in the Guide database. |
Note that even when the LE_LOUD flag is set in the dwFlags parameter, WebTV for Windows is notified only if the loaded enhancement matches the next episode listed in the Guide database. For example, if an enhancement for a December show is loaded in October, the enhancement is saved in the database, but WebTV for Windows is not notified. This is because the December episode is not yet listed in the Guide database as occurring next.
Returns an HRESULT indicating success or failure. If the method succeeds, it returns S_OK. Otherwise, it returns an error code. For specific error codes, see the Winerror.h and Dbdaoerr.h header files. To locate more information about Winerror.h and Dbdaoerr.h, see Further Information on Television Services for the Client.
Windows NT: Unsupported.
Windows: Requires Windows 98.
Windows CE: Unsupported.
Header: Declared in tssadmin.odl.
Import Library: Included as a resource in tssadmin.dll.
Unicode: Yes.
ITelevisionServices::DeleteEnhancementFromID, ITelevisionServices::DeleteOldEnhancements, ITelevisionServices::LoadEnhancementsFromFile, ITelevisionServices::RemapEnhancements