Total Commander Ultima Prime

One For All


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Xn Convert in Button Bar with drag'n'drop
#1
Hi!

Is it possible to create button for Xn Convert in the button bar and drag'n'drop selected files to it?

In menu is works like this:
Cmd=%COMMANDER_PATH%\Plugins\Tools\XnConvert\XnConvert.exe
Param=@%L "-output=%T"

Both selected files and target path are detectednand passed to the converter. But if you'll try to do the same in the button bar, it just won't work.

I have also tried to use %p%n and %s, but it just doesn't work.

Any ideas?
Reply
#2
(11-29-2009, 11:57 AM)damat Wrote: Hi!

Is it possible to create button for Xn Convert in the button bar and drag'n'drop selected files to it?

In menu is works like this:
Cmd=%COMMANDER_PATH%\Plugins\Tools\XnConvert\XnConvert.exe
Param=@%L "-output=%T"

Both selected files and target path are detectednand passed to the converter. But if you'll try to do the same in the button bar, it just won't work.

I have also tried to use %p%n and %s, but it just doesn't work.

Any ideas?
It works...if you select and click, but not when you drag and drop. That's because if you drop a file, TC ignores Param field and sends just the file.
Normally, you can work around it by putting parameters in the cmd field, but TC doesn't replace parameters like %T with their values if you put them in cmd, so it works only when parameters other than the file name are invariable.
Another way is using a batch files that adds the required parameters (it's stronger, because with this approach file names don't have to come last). But it won't be able to guess the target path either.

I think that you can't do it simpler than with an AHK script that gets the path and sends together with the files to XnConvert.
Reply
#3
Thanks a lot! It really works as it should on click

But how does AIMP work, when you drag'n'drop folder or several selected files?
Reply
#4
(11-29-2009, 02:09 PM)damat Wrote: Thanks a lot! It really works as it should on click

But how does AIMP work, when you drag'n'drop folder or several selected files?
When you drag'n'drop, TC sends the dropped thing in the command line.
The problem with XnConvert is that TC doesn't send the output path.

For AIMP it's enough, XnConvert needs the output path.
Reply
#5
But when I just drag'n'drop files to XnConvert, no files appear in Input. That's the reason of my frustration =)
Reply
#6
(11-29-2009, 02:40 PM)damat Wrote: But when I just drag'n'drop files to XnConvert, no files appear in Input. That's the reason of my frustration =)

Strange. Here they do.
Can you try a button with the following command (all in the 'command' field):
Code:
cmd /k echo
?

ADDED: And is it a problem with all or just some files? I'm thinking about Unicode, but there are might be other showstoppers too.

ADDED2:
I see that XnConvert has problems if there are spaces somewhere in path.
It seems like a bug, we should contact XnConvert devs. Is it the problem?
Reply
#7
You are very kind, thanks for digging in!

It's not a problem really, I just wanted to have it in the button bar. It's completely ok to click.

If you think that it will be useful to post a bug, feel free to do it =)

And thanks again!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)