Find()

Finds a character string in the From, Subject, or Message edit boxes.

Token ID

AFTKN_SEARCH or 627

Syntax

VOID Find([ANSISTRING FromSearchString]; 
           [ANSISTRING SubjectSearchString]; 
           [ANSISTRING MessageSearchString]; 
           [ENUM SearchDir]; 
           [ENUM FromMatch]; 
           [ENUM SubjectMatch]; 
           [ENUM MessageMatch])

Parameters

FromSearchString As ANSISTRING

(Optional) From edit box character string.

SubjectSearchString As ANSISTRING

(Optional) Subject edit box character string.

MessageSearchString As ANSISTRING

(Optional) Message edit box character string.

SearchDir As ENUM

(Optional) Search forward or backward from the insertion point:

  • 0 Forward (Default)
  • 1 Backward
FromMatch As ENUM

(Optional) From edit box match criteria, as follows:

Value

Position

Description

127

BeginText

Matches a string from the first character to the length of the search string.

165

FullText

Matches an exact string and is case-sensitive.

225

SubText

Default. Matches any substring.

SubjectMatch As ENUM

(Optional) Match criteria for the Subject edit box, as follows:

Value

Position

Description

127

BeginText

Matches a string from the first character to the length of the search string.

165

FullText

Matches an exact string and is case-sensitive.

225

SubText

Default. Matches any substring.

MessageMatch As ENUM

(Optional) Match criteria for the Message edit box, as follows:

Value

Position

Description

127

BeginText

Matches a string from the first character to the length of the search string.

165

FullText

Matches an exact string and is case-sensitive.

225

SubText

Default. Matches any substring.

Remarks

A NotFound condition occurs if you use FromSearchString, SubjectSearchString, and MessageSearchString, and one or more does not find a match.

When you search only one edit box, you must include the parameter name. For example, the following line searches forward from the insertion point for "John" in a From edit box.

Find(FromSearchString: "John"; SearchDir: Forward!; FromMatch: SubText!)