load search template and open search box directly
-
yusef88
- Posts: 1148
- Joined: 28 Jan 2013 03:50
- Location: Windows 8.1 32-bit
load search template and open search box directly
can i load search template and open search box directly instead press ctrl+f then load template
To see the attached files, you need to log into the forum.
-
highend
- Posts: 14954
- Joined: 06 Feb 2011 00:33
- Location: Win Server 2022 @100%
Re: load search template and open search box directly
Scripting would help...
Depending on what you need, you eventually have to edit the "x" (see help file for loadsearch()).
Code: Select all
$template = popupmenu(replace(listfolder("<xydata>\FindTemplates", "*.ini", 4), ".ini"));
loadsearch $template, "x";
#260;One of my scripts helped you out? Please donate via Paypal
-
yusef88
- Posts: 1148
- Joined: 28 Jan 2013 03:50
- Location: Windows 8.1 32-bit
Re: load search template and open search box directly
excellent
your script leads me to read in help file, to load certian template i use this
loadsearch "1", l ;#260;
loadsearch "1", l ;#260;
-
yusef88
- Posts: 1148
- Joined: 28 Jan 2013 03:50
- Location: Windows 8.1 32-bit
Re: load search template and open search box directly
why variables like "%computer%" "%programfiles%" don't work in find files
To see the attached files, you need to log into the forum.
Last edited by yusef88 on 18 Jun 2014 23:56, edited 1 time in total.
-
highend
- Posts: 14954
- Joined: 06 Feb 2011 00:33
- Location: Win Server 2022 @100%
Re: load search template and open search box directly
For the location field?
%programfiles% works fine for me...
%programfiles% works fine for me...
One of my scripts helped you out? Please donate via Paypal
-
yusef88
- Posts: 1148
- Joined: 28 Jan 2013 03:50
- Location: Windows 8.1 32-bit
Re: load search template and open search box directly
try it in excluded folders it won't work
-
highend
- Posts: 14954
- Joined: 06 Feb 2011 00:33
- Location: Win Server 2022 @100%
Re: load search template and open search box directly
You should be able to exclude it when you store it with the template and use the "e" option for loadsearch()try it in excluded folders it won't work
One of my scripts helped you out? Please donate via Paypal
-
yusef88
- Posts: 1148
- Joined: 28 Jan 2013 03:50
- Location: Windows 8.1 32-bit
Re: load search template and open search box directly
Code: Select all
::loadsearch "pc", l;#260;"-
highend
- Posts: 14954
- Joined: 06 Feb 2011 00:33
- Location: Win Server 2022 @100%
Re: load search template and open search box directly
Extend the script by making a temp version of the template and insert what's currently in the clipboard into it and load that one instead.
One of my scripts helped you out? Please donate via Paypal
-
yusef88
- Posts: 1148
- Joined: 28 Jan 2013 03:50
- Location: Windows 8.1 32-bit
Re: load search template and open search box directly
mean like this?
but what is the clipboard is variable and change every time i need something similar to that
Code: Select all
[Named]
Named="Test"Code: Select all
tab("new", "<clipboard>");Code: Select all
?"<clipboard>"-
highend
- Posts: 14954
- Joined: 06 Feb 2011 00:33
- Location: Win Server 2022 @100%
Re: load search template and open search box directly
No... Templates don't support variables that you can only get by scripting.
Code: Select all
$template = "<xydata>\FindTemplates\pc.ini";
$content = regexreplace(readfile($template), "^(Named="")([^""]+)", "$1<clipboard>");
writefile($template, $content);
loadsearch getpathcomponent($template, "base"), "l";One of my scripts helped you out? Please donate via Paypal
-
yusef88
- Posts: 1148
- Joined: 28 Jan 2013 03:50
- Location: Windows 8.1 32-bit
Re: load search template and open search box directly
it works perfectly,thanks 
XYplorer Beta Club