Page 1 of 1

focus search box in inputselect

Posted: 18 Sep 2014 12:24
by yusef88
recent loctions

Code: Select all

::#539;
recent files

Code: Select all

open inputselect("Recent Files", get("list_recentlyopenedfiles"), <crlf>, 5);
in first command, search box is focused and selected by default..can make same thing in the second?

Re: focus search box in inputselect

Posted: 18 Sep 2014 12:42
by highend
Em, just read the docs for inputselect()?

Hint: style

Re: focus search box in inputselect

Posted: 18 Sep 2014 13:03
by klownboy
Hi yusef88,
Try this is the address box. I had to use sendkeys before the command instead of after but it does work for me.

Code: Select all

::sendkeys "{tab}"; open inputselect("Recent Files", get("list_recentlyopenedfiles"), <crlf>, 5);
I just noticed highends's suggestion..using 69 instead of 5. That works w/o having to use sendkeys approach.
Ken

Re: focus search box in inputselect

Posted: 18 Sep 2014 15:00
by TheQwerty
Tip: For bit flags let XY do the math - your future self will thank you for saving them from the simple arithmetic.

This should work as you want:

Code: Select all

open inputselect("Recent Files", get("list_recentlyopenedfiles"), <crlf>, 1+4+32+64);
I added the 32 flag to auto-select the first item making it easy to open the most recent file using just Tab > Enter.

Re: focus search box in inputselect

Posted: 18 Sep 2014 19:06
by yusef88
@klownboy @TheQwerty
really appreciate your help..thanks :D and this also works thanks for the hint,highend :wink:

Code: Select all

open inputselect("Recent Files", get("list_recentlyopenedfiles"), <crlf>, 97);