GetNewestHeadlineFromSelectionSet Method (Headline Control)
Windows - Visual C++
Description
The
GetNewestHeadlineFromSelectionSet method returns the most recently
received headline in the specified selection set.
Syntax
long result =
GetNewestHeadlineFromSelectionSet(long selectionSetID, long* storyID,
BSTR* headlineText);
The GetNewestHeadlineFromSelectionSet syntax has these parts:
Part |
Description |
selectionSetID |
A long integer containing the selection set ID. |
storyID |
A long integer that receives the story ID of the most recently received headline in the selection set. |
headlineText |
A String that receives the text of the headline, as described in Remarks. |
result |
A long integer containing 0 if successful and an error code if not. |
Remarks
The
GetNewestHeadlineFromSelectionSet method is used to sequentially
obtain each headline in a selection set created with the SaveSelectionSet
method. Once a headline is returned by
GetNewestHeadlineFromSelectionSet it is no longer a part of the
selection set. The next time that GetNewestHeadlineFromSelectionSet
is called, the next most recently received headline will be returned
and so on, until the selection set is empty, at which point the error
code DDICTL_E_R_NOMORESELHDL is returned by the function.
Note that you should not use the value returned by GetNumberSelected to determine how many times to call GetNewestHeadlineFromSelectionSet, since it is possible that the number of headlines in the set may change.
Each field in the headlineText parameter is separated by a carriage return character (vbKeyReturn). The fields contained in the string are in the following order: Date, Time, Feed, Profiles, Rank, Headline.
See Also: DeleteSelectionSet GetNumberSelected GetOldestHeadlineFromSelectionSet SaveSelectionSet
Back to: Headline Methods