Search_Screen

Searches the screen for the supplied text. The rows to be searched can be specified, where 1 is the top row. If the bottom row value is less than 1, searching continues to the bottom of the screen. If Ignore Case is TRUE, then upper-case and lower-case letters are considered to be equal.

Parameters

Search String

The string to find on the screen.

Top Search Row

The row in which the search begins.

Bottom Search Row

The row in which the search ends.

Ignore Case

Indicates whether the case of the letters is taken into consideration.

Format

Search_Screen (Search String, Top Search Row, Bottom Search Row, Ignore Case)

Return Value

Returns a Boolean. TRUE if the text is found, FALSE otherwise.

Example

Script( Search_Screen_Test )
String( strSearch )
Boolean( bFound )
Boolean( bIgnoreCase )
Number( nStartRow )
Number( nEndRow )
Activate( From_Menu )
strSearch = Ask_String( "Enter string to search for", "Search_String_Test", 0, 999, "" )
nStartRow = Ask_Number( "Enter starting row (1 is top of screen)","Search_String_Test", 0, 999, 0 )
bIgnoreCase = Ask_Yes_No( "Ignore case?", "Search_String_Test", FALSE )
bFound = Search_Screen( strSearch, nStartRow, nEndRow, bIgnoreCase )
If( bFound )
Message( "Search string found.", 5 )
Else
Message( "Search string not found.", 5 )
End_If
Return

See Also

Get_Screen_Rows, Get_Position_Row, Get_Field_Row, Get_Field_Index, Set_Field_Data_ID, String_Set, Ask_String

 


Was this article useful?    

The topic was:

Inaccurate

Incomplete

Not what I expected

Other

Privacy and Legal