Syntax


FF 

string

[ start-column [ end-column ] ]  

[ CHARS | WORD | PREFIX | SUFFIX ]  

[ NF ]



Operands


string

Any string value accepted in an edit session is permitted here. The string may be unquoted, or quoted without a string type, or may be quoted with a string type of C, T, X, P or R


Unquoted strings, or string quoted without a string type, will be treated as either C or T, depending on the CASE C/T code that appears on the SPFLite status line. The CASE C/T code for the File Manager can be changed by the CASE command, the same as in an Edit or Browse session.


start-column

Left column of a range (with end-column) within which the search-string value must be found. If no end-column operand, then the search-string operand must be found starting in start-col.


end-column

Right column of a range (with start-column) within which the search-string value must be found.


CHARS

WORD

PREFIX

SUFFIX

Specifies the ‘search context' for the string, the same as is done for the FIND command in the editor. 


If not specified, a CHARS search is done if the status line shows C or T, and a WORD search is done if the status line shows C W or T W. These two defaults can be set by the FIND CHARS and FIND WORDS commands, as in an edit tab.


NF

If the NF option is used, a search is made for files that do not have the string present on any line.

 

Abbreviations and Aliases


PREFIX can also be spelled as PRE or PFX

SUFFIX can also be spelled as SUF or SFX

WORDS can also be spelled as WORD

CHARS can also be spelled as CHAR


Operational Note Regarding the File Patterns Field


When the Find in Files command FF is issued in the File Manager tab, the current File Patterns mask is used to select one or more file patterns to search for. Due to the timing of how SPFLite processes the File Patterns field, the file mask you wish to use must already be in effect when the FF command is issued. 


In practice, this means that you cannot change the File Patterns field AND issue the FF command at the same time.  If you attempt to do that, SPFLite will use the last-known File Patterns field instead of the one you just entered. That means you could end up searching files you didn't intend to search.


The correct way to handle this situation is to (a) modify the File Patterns field as desired; (b) Press Enter; (c) type the desired FF command and press Enter a second time.


This issue only applies to when the File Patterns entry field is visibly displayed, which will be on a standard directory display. If you issue a Find in Files command FF on some other list, such as the Recent list or a user-defined FLIST, a File Patterns field is not available, and the search is then limited to the files displayed.


Description


The Find in Files command FF is issued in the File Manager tab. It references each file in the currently displayed directory list or File List. For each file in the displayed list, the Find in Files command FF will look for the string in the file, in the same way that a FIND command looks for strings in an edit file, applying string types C, T, X, P or R and search types CHARS, WORD, PREFIX or SUFFIX likewise in the same way. 


If the string is found anywhere in the file (or, if the NF option is used and the string is not found anywhere in the file), the file is remembered as meeting the File in Files search criteria. Once all the files in the original list have been examined, the Find in Files command FF creates the Found Files File List, and the files in this Found Files File List become the current list of files displayed in File Manager.


You can then use the Found Files File List to search again, refining your list by searching for additional strings, or you can use the Found Files File List to enter File Manager line commands as usual.


If you wish to edit all files together containing a certain string, you can use the Find in Files command FF to locate them, and use the Multi-Edit line command M on each file to being a multi-edit session using all the files you found in the search process. You can also use the File Manager ALL command to edit or Multi-edit every file listed in a File List.


When you issue a Find in Files command FF and then open the Found Files File List, the FF command, and all options that were specified with it, will appear on the top line of the display, like this:


       FILELIST > Found Files: FF T'ABC'


This will help in keeping track of and remembering what was being searched for, especially in cases where the FF command might have been done previously, and the Found Files FILELIST is being redisplayed (perhaps long) after the time it was created.


You can find additional information and examples in Performing Searches with Find In Files.


Note:  The Find in Files command FF should not be confused with the new FF alias for the edit primary command FIND; the two commands are not related. However, if you issue a File Manager command of FF ABC, and then open a file listed in the Found FIles FILELIST, you can quickly find the string ABC by retrieving the FF command (usually by the command mapped to F12). Assuming there is no outstanding CC or MM blocks in the edit file, the FF ABC in the edit session will find the string ABC within the file, the same way that a regular FIND edit command would. This can be a time-saving shortcut.



Created with the Personal Edition of HelpNDoc: Easily share your documentation with the world through a beautiful website