Internet Direct (Indy)
Home
PreviousUpNext
TIdNNTP.XHDR Method (string, string)

NNTP extension to retrieve article headers using selection criteria. 

Approved Lines Xref  

The range of articles to be searched is specifies by the AParm argument. AParm must be in the following forms: 

 

an article number 
an article number followed by a dash to indicate all following articles 
an article number followed by a dash and another article number 

 

For example, if the following values of AParm would result in the corresponding action: 

 

23 
retrieve article number 23. 
1-23 
retrieve all available articles number in the range 1 through 23. 
23- 
retrieve all articles numbered 23 and higher. 

 

XHDR relies on the OnXHDREntry event handler to signal receipt of an XHDR response the NNTP server. An EIdNNTPNoOnXHDREntry is raised if the OnXHDREntry event handler is unassigned during a call to XHDR. 

You must have previously executed the SelectGroup command in order for this command to return a meaningful response. 

Article numbers are transitory. This means that you may specify a range of article numbers, such as 1-5, and you may receive only articles 1,3 and 4. This does not mean you have done anything wrong. The missing articles may have been expired (removed from the server), or for some other reason not under your control have become unavailable.

Pascal
procedure XHDR(
    AHeader: string; 
    AParam: string
); overload;
Parameters 
Description 
AHeader 
Header to be searched.
 
AParm 
Range of articles to search. 

XHDR is a method that retrieves specific article headers specified in AHeader from an article index or a range of articles as specified in AParam. XHDR is an extension to the NNTP protocol. 

XHDR calls SendCmd using the arguments in AHeader and AParam. 

AHeader can contain any of the following values for an RFC 1036-compliant server: 

 

From 
Date 
Newsgroups 
Subject 
Message-ID 
Path 

 

The following headers may or may not work depending on the server configuration. Also, it should be noted that servers can and many do have local header definitions. If you know what these header designations are you can of course pass them in the AHeader argument. 

 

Reply-To 
Sender 
Followup-To 
Expires 
References 
Control 
Distribution 
Organization 
Keywords 
Internet Direct (Indy) version 10.1.5
Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Website http://www.indyproject.org.
Post feedback to the Indy Documentation newsgroup.