Routine to open search all blank form

I prefer to have the preference for search/find set to Select, Current Field. I have a procedure to select text on clipboard in all fields; works great.

What I need is a procedure to open the Select form/window set to “Any field contains”.

I doubt there’s a way to preset the search dialog as you’re describing. You can use something like GetText though to enter what it is you’re seeking, then select using export line()

Let lvInput = ""
GetText "Find what?",lvInput
If lvInput = ""

select exportline() contains lvInput

James, I beg your pardon, but in fact there is a way to modify the Search Preference.

You can get the recent Search preference value with this code:

nsnotify getpreferencevalue("PXDefaultSearch")

You can set the Search preference value to “All fields” with this code:

setpreferencevalues "PXDefaultSearch","All fields"

You can set the Search preference value to “Current field” with this code:

setpreferencevalues "PXDefaultSearch","Current field"

For most users it’s probably going to be easier to use the Preferences window rather than writing code to change the settings.