Help > Web Development > Object Reference > Object Reference > ISYSDocument > GetLineWithHitBefore Method
<a name="kanchor318"></a>ISYSDocument:GetLineWithHitBefore Method
Returns the number of the line with the previous hit before the specified line.

Syntax
[VBScript]
function ISYSDocument.GetLineWithHitBefore(_
  long Line_ 
) as long
[C#]
long IISYSDocument.GetLineWithHitBefore(
  long Line
);
[ColdFusion/Java]
long IISYSDocument.GetLineWithHitBefore(
  long Line
) throws ComException;
Parameters
LineThe line number before which to find the previous hit

Examples
[VBScript]
<% ' Execute the search object and get the results Set Results = ISYSSearch.Execute ' Get the first document Set Document = Results(1) ' Display 3 line before the the last hit lastHit = Document.GetLineWithHitBefore(Document.LineCount + 1) For i = lastHit-3 downto lastHit if i > 1 then Response.Write Document.Line(i, isysStylePlain) Next %>
See Also