Foundation 6

Fnd_Find

21 shared methods.

Fnd_Find_AddCustom

Fnd_Find_AddCustom (label; method name{; position})

Adds a custom field to the search dialog.

ParameterTypeDirectionDescription
labelTextinThe label to use
methodTextinThe method to call
inPositionLongintinThe position (optional)

Fnd_Find_AddField

Fnd_Find_AddField (->field{; position})

Lets the developer add a field to the search dialog. If a position isn't specified, the field is added to the end of the list.

ParameterTypeDirectionDescription
fieldPointerinA pointer to the field to add
inPositionLongintinThe position in which to add the item (optional)

Fnd_Find_AddItem

Fnd_Find_AddItem (position; label; method{; ->field{; type}})

Called by the protected "Fnd_Find_Add" routines to add stuff to the arrays.

If the label is blank, the field name will be used.

ParameterTypeDirectionDescription
inPositionLongintinThe position
labelTextinThe label
methodTextinThe method
inFieldPointerinThe field (optional)
inFieldTypeLongintinThe field's type (optional)

Fnd_Find_AddMultiField

Fnd_Find_AddMultiField (->array of field ptrs; label{; position})

Lets the developer add one item for searching multiple fields.

ParameterTypeDirectionDescription
fieldPointerinA pointer to an array of pointers
labelTextinThe label for the popup item
inPositionLongintinThe position in which to add the first item (optional)

Fnd_Find_AddSeparator

Fnd_Find_AddSeparator ({position})

Adds a separator line to the list of searchable fields.

ParameterTypeDirectionDescription
inPositionLongintinPosition of the separator (optional)

Fnd_Find_AddSubfield

Fnd_Find_AddSubfield (->subfield; field type{; position})

Lets the developer add a subfield to the Find dialog. The field type must be specified because we can't procedurally determine this like we can for fields. If a position isn't specified, the field is added to the end of the list.

ParameterTypeDirectionDescription
fieldPointerinA pointer to the field to add
fieldTypeLongintinThe type of the subfield
inPositionLongintinThe position in which to add the item (optional)

Fnd_Find_AddTable

Fnd_Find_AddTable (->table{; position})

Loads the visible, searchable fields for the specified table into an array named Fnd_Find_Fields_aptr.

ParameterTypeDirectionDescription
tablePointerinA pointer to the table to add
inPositionLongintinThe position in which to add the item (optional)

Fnd_Find_BestPopupSize

Fnd_Find_BestPopupSize (->popup array) --> Number

Returns the best object width to use for a pop-up menu form object.

ParameterTypeDirectionDescription
arrayPointerinThe array associated with the popup
ResultLongintoutThe best object size for the pop-up

Fnd_Find_Display

Fnd_Find_Display

Displays a Find dialog and performs the query.

No parameters.

Fnd_Find_Engine

Fnd_Find_Engine ("Query" or "Query Selection")

Does the grunt work.

ParameterTypeDirectionDescription
searchScopeTextinEither "Query" or "Query Selection"

Fnd_Find_Engine2

Fnd_Find_Engine2 ("Query" or "Query Selection"; ->field; operator)

Adds a query to the built search.

ParameterTypeDirectionDescription
searchScopeTextinEither "Query" or "Query Selection"
fieldPointerinA pointer to the field to search
operatorTextinThe operator code to use

Fnd_Find_Engine3

Fnd_Find_Engine3 ("Query" or "Query Selection"; ->field; operator)

Adds a query to the built search.

Exactly the same as Fnd_Find_Engine2, but with "|" operators.

ParameterTypeDirectionDescription
searchScopeTextinEither "Query" or "Query Selection"
fieldPointerinA pointer to the field to search
operatorTextinThe operator code to use

Fnd_Find_GetExtraWidth

Fnd_Find_GetExtraWidth --> Number

Returns the extra width needed to display the Find dialog so none of the text in the pop-up menus gets truncated.

Lots of stuff is hard-coded here because we can't get it procedurally. :-(

ParameterTypeDirectionDescription
ResultLongintoutThe extra width required

Fnd_Find_Info

Fnd_Find_Info (label) --> Text

Returns requested information. See the Fnd_Gen_ComponentInfo method for more information.

ParameterTypeDirectionDescription
requestTextinInfo desired ("version" or "name")
ResultTextoutResponse

Fnd_Find_Localize

Fnd_Find_Localize

Passed the localization strings to the General and (if available) Localization components.

No parameters.

Fnd_Find_Now

Fnd_Find_Now ("Query" or "Query Selection")

Finishes up the built search. This is separate from the Fnd_Find_Engine routine so it's possible to change the dialog to a multi-criteria find.

ParameterTypeDirectionDescription
searchScopeTextinEither "Query" or "Query Selection"

Fnd_Find_PrefsGet

Fnd_Find_PrefsGet (pref name) --> Text

Gets a value from the user preferences if the Fnd_Pref component is available.

ParameterTypeDirectionDescription
prefNameTextinThe preference name
ResultTextoutThe saved value

Fnd_Find_PrefsPut

Fnd_Find_PrefsPut (pref name; text value)

Adds an item to the user's preferences if the Fnd_Pref component is available.

ParameterTypeDirectionDescription
nameTextinThe preference name
valueTextinThe value to store

Fnd_Find_SetEditorButton

Fnd_Find_SetEditorButton (label{; method})

Allows the developer to hide or modify the Query Editor button.

ParameterTypeDirectionDescription
labelTextinThe new label
inMethodTextinThe method to run (optional)

Fnd_Find_SizeArrayObject

Fnd_Find_SizeArrayObject (->object; alignment) --> Number

Sets the best size for an array based form object based on the contents it displays.

Rather than using BEST OBJECT SIZE, we calculate the size the same way we did before opening the dialog using the Fnd_Find_GetExtraWidth method.

ParameterTypeDirectionDescription
objectPointerinA pointer to the form object
alignmentLongintinThe alignment (side not to move)
ResultLongintoutThe increase in the button size

Fnd_Find_UpdateOperators

Fnd_Find_UpdateOperators

Updates the Search Operators pop-up menu depending on the type of the selected field.

No parameters.