Page 1 of 1

User Commands in Catalog

Posted: 09 Apr 2014 09:23
by Ramesh
I have created a new user command with the command ID #1400. This is a script for moving selected files to one or more folders which is displayed as a menu to the user (depending on the choice made by the user, the selected files gets moved to that folder).

I tried adding this user command to the catalog using command ID #1400 (which is the command ID for the script), by typing "::#1400" in the location field for the catalog item. Whenever I click the catalog item, I get an error message - "Nothing selected or what is selected cannot be moved" followed by a dialog box which states that the Command "moveto" failed or was cancelled.

The user command works perfectly when I execute it from "User" menu - Run Script.

Can you pls let me know if I can add user commands to Catalog and whether the process that I followed is correct or is it a bug in Xyplorer?

Re: User Commands in Catalog

Posted: 09 Apr 2014 09:37
by Enternal
Perhaps could you post the script code so that it can be tested? I had similar issues before but it was due to some scripting command I used.

Re: User Commands in Catalog

Posted: 09 Apr 2014 12:01
by Ramesh
This is the script that I have used in user Command

"MoveTo Best Practices"
MoveTo "C:\Backup\My Files\Quick Access\Best Practises\"

Re: User Commands in Catalog

Posted: 09 Apr 2014 14:26
by admin
Your script need to focus the list first. Because when you click the catalog the focus is on the catalog.

Code: Select all

focus "L";
[moved the topic to questions]

Re: User Commands in Catalog

Posted: 10 Apr 2014 08:41
by Ramesh
Thanks. Can you please also add an example in your website for the benefit of other users.

Re: User Commands in Catalog

Posted: 10 Apr 2014 08:53
by Stef123
Trying to reproduce:
User Commands > Move To: Where do I insert the <<focus "L";>> ?

Re: User Commands in Catalog

Posted: 10 Apr 2014 09:22
by highend
He ist using Run Script, not Move To as the category in the user commands :)

Re: User Commands in Catalog

Posted: 10 Apr 2014 10:32
by Stef123
Thanks highend,
Scripting is still intimidating me. :? Reluctant to get into it. :whistle:
I can see the fun you all have with it. But I also noticed it often takes several passes to get it right. Not always do I have as much time at hand as these days.

When I am out again in the heat of business I need to feel in control, competent and able to fix small issues on the spot. Not a good time to debug when your attention is bound up elsewhere.

Catalog: I tried that user command to move a folder (because I noticed the catalog won't adapt the path if I move it in the list.
1) Will it do so if I get the move to work from the catalog?
2) Could someone please walk me through? What goes where, field-wise.