GP SoftwareTwitter
Opus FAQsManualCommandsObjects

Making the FIND window close as soon as it has done its job

I also tried setting the pin on my find window, so that ESC would work.

But it doesn't work. The FIND window loses focus so I have to refocus it before hitting ESC

Annoying.

[quote="dwilbank"]The FIND window would close as soon as all the results have been found.
(I certainly don't want the results window to close automatically)[/quote]

Oh, ok, that makes sense. Sorry, i got it wrong. Did you send a feature request to GPSoft?

gpsoft.com.au/Support.html

What sort of Find are you doing? If it's a simple filename/wildcard search, or one using a saved filter (that you don't need to modify each time) then you can do it but not otherwise.

BTW, if you haven't noticed it, there is also a Find panel in the Tools menu which is (IMO) better than the standalone Find window in most situations.

It's a preset search of 7 drives where I type in a new string every time.

The Tool menu Find does seem nice, but it also takes up screen space after it has found its results.

Any hotkey to collapse it?

ALT-T, N doesn't close it consistantly...

What is the string you type? A simple filename pattern or something else?

I just type a barcode - like v0085588998

and it searches 7 drives and returns the results in a collection window

and the original FIND box just hangs there in the way -

But are you searching for that in the filenames, or in the file contents, file descriptions or something else?

in the filenames only

In that case you can make a button like abr suggests in this thread:

[ul][li]How to automatically close the Find Tool dialog?[/li][/ul]

It will prompt you for what to search for and then start showing you the results without the Find window or panel ever being opened.

woohoo - exactly!

Thanks

coworker is really liking this quiet mode find function

Now, to eliminate the need to type a wildcard between every word, how would I go about making something that would replace every space with an asterisk, and put one at the beginning and end of my string as well?

I think you'd have to expand the simple command that abr provided to include some scripting glue to do the sort of character replacement you're asking for... Maybe there are other ways - but using the ability to "abuse rename scripts to do other things" in Opus can help you do this... as an example, here's the XML button code for one way you could try this:

Note: there is a variable called delim in the code that is currently set to " " to give the ability to use spaces like you asked as the delimiting character between different filename parts. If you find that you want your searches to include spaces, then you can set this variable to some other value (such as a slash character). Also note that the dialog that appears defaults to pre-populating the input field with whatever is in your clipboard, and "highlights" it for quick overwriting with whatever else you might want to search for. You can change all of that as well to pre-populate the dialog with ANY or NO text at all, and/or to NOT highlight whatever you might use as default search text... At any rate, what I've included below is just an example of little things you can do with Opus that I find useful...

<?xml version="1.0"?> <button display="both" icon_size="large" label_pos="right"> <label>Test Find Button</label> <tip>Test Find Button</tip> <icon1>#findpane</icon1> <function type="normal"> <instruction>Rename FILEINFO FROM=&quot;.&quot; TO=&quot;{RS|Filename strings to search for:|{clip}}&quot;</instruction> <instruction>@script vbscript</instruction> <instruction>Option Explicit</instruction> <instruction /> <instruction>Dim objShell</instruction> <instruction>Set objShell = CreateObject(&quot;WScript.Shell&quot;)</instruction> <instruction /> <instruction /> <instruction>Function Rename_GetNewName(strFileName, strFilePath, fIsFolder, strOldName, ByRef strNewName)</instruction> <instruction /> <instruction> Dim delim, wildcard, strCommand, vbQuote</instruction> <instruction> delim = &quot; &quot;</instruction> <instruction> wildcard = &quot;*&quot;</instruction> <instruction> strCommand = &quot;&quot;</instruction> <instruction> vbQuote = Chr(34)</instruction> <instruction /> <instruction> strCommand = vbQuote &amp; &quot;C:\Program Files\GPSoftware\Directory Opus\dopusrt.exe&quot; &amp; vbQuote &amp; &quot; /cmd Find in C: D: NAME &quot; &amp; vbQuote &amp; &quot;*&quot; &amp; Replace(strNewName,delim,wildcard) &amp; &quot;*&quot; &amp; vbQuote &amp; &quot; QUIET SHOWRESULTS=tab&quot;</instruction> <instruction /> <instruction> &apos; Set strNewName to an empty string so that Opus does not rename the file</instruction> <instruction> strNewName = &quot;&quot;</instruction> <instruction /> <instruction> Set objShell = CreateObject(&quot;WScript.Shell&quot;)</instruction> <instruction> objShell.Run strCommand, 1, False</instruction> <instruction /> <instruction> Set objShell = Nothing</instruction> <instruction /> <instruction>End Function</instruction> </function> </button>

Sir.
This button is a work of art.
I bow before this button.
Where would I put in the drive letters I want to include in the default search, i.e., "C:" "G:" R:", etc...

There's a part in the button that sets the actual find command as part of the strCommand string: Find in C: D: NAME etc


Just change my example of using C: D: to your preferred drives (you can specify full folder paths as well) such as in your example: Find in C: G: R: NAME etc

Thanks!
Didn't see that in there before.

Maybe I just didn't scroll down far enough in that window.

Sure thing - hope it's useful to you.

Mr. Steje.

You had a magic way of removing the need for a wildcard in the search box.

Is there some way to do the same thing when I'm typing in a lister and I want to filter the files I see?

Right now when I just start typing, the little box at the bottom tints red and goes into a FIND mode. When I type a slash, it turns into a blue GO mode. When I type * it goes into purple filter mode. What is this feature called so I can look it up in the manual and see how to make modifications?

Thx

[quote="dwilbank"]
Right now when I just start typing, the little box at the bottom tints red and goes into a FIND mode. When I type a slash, it turns into a blue GO mode. When I type * it goes into purple filter mode. What is this feature called so I can look it up in the manual and see how to make modifications?[/quote]

Look for "Find-As-You-Type".

Thx

Once I did that, it led me to this:

gpsoft.com.au/manual9/nethel ... bykeys.htm
where I learned a few new tricks
now if I could only learn how to alter the behavior of this feature...

The filter box might do what you want: https://resource.dopus.com/t/legacy-faq-add-and-configure-filter-boxes/1314/1