Page 1 of 1
Use of UDC's
Posted: 19 Nov 2007 12:44
by jcmn
I have the following command line for an aplication and I want to create a UDC for it:
"C:\Program Files\StatNeth\Blaise 4.7 Enterprise\Bin\dep.exe" file1 /Ffile2
How to implement a UDC so that I can select in the list view the two files (file1 and file2) in the proper order?
Re: Use of UDC's
Posted: 19 Nov 2007 12:48
by admin
jcmn wrote:I have the following command line for an aplication and I want to create a UDC for it:
"C:\Program Files\StatNeth\Blaise 4.7 Enterprise\Bin\dep.exe" file1 /Ffile2
How to implement a UDC so that I can select in the list view the two files (file1 and file2) in the proper order?
Ah, interesting task. It's not possible yet.
Explain shortly what you need in general terms. Is it that you always pass 2 files to be compared or so?
Posted: 19 Nov 2007 13:05
by jcmn
What I need is to select the file1 and file2 in the folder list (they are in the same folder) in a manner that XYPlorer can distinguish them.
file1 is a configuration file and file2 is a data file. They have different extensions (file1 has BMI extension and file2 has BDB extension).
For example can I use
"C:\Program Files\StatNeth\Blaise 4.7 Enterprise\Bin\dep.exe" <items>.bmi /F<items>.bdb
or is it
"C:\Program Files\StatNeth\Blaise 4.7 Enterprise\Bin\dep.exe" <base>.bmi /F<base>.bdb
Posted: 19 Nov 2007 13:53
by admin
jcmn wrote:What I need is to select the file1 and file2 in the folder list (they are in the same folder) in a manner that XYPlorer can distinguish them.
file1 is a configuration file and file2 is a data file. They have different extensions (file1 has BMI extension and file2 has BDB extension).
For example can I use
"C:\Program Files\StatNeth\Blaise 4.7 Enterprise\Bin\dep.exe" <items>.bmi /F<items>.bdb
or is it
"C:\Program Files\StatNeth\Blaise 4.7 Enterprise\Bin\dep.exe" <base>.bmi /F<base>.bdb
Currently you cannot do it with XY. But I'll add it. I probably add 2 or 3 new variables of the form <item1>, <item2>, <item3>. Item 1 is always the focused one, and item 2 is the next one (in the current list order), etc.
Posted: 19 Nov 2007 14:32
by TheQwerty
admin wrote:Currently you cannot do it with XY. But I'll add it. I probably add 2 or 3 new variables of the form <item1>, <item2>, <item3>. Item 1 is always the focused one, and item 2 is the next one (in the current list order), etc.
I had wanted to request something similar but couldn't think of a good way to do this. That sounds like it will work fine but might be a tad confusing to new users.
Slightly off topic, could we get a variable <path> (or similar) which contains the current working path regardless of selection? (Or does one already exist?)
Posted: 19 Nov 2007 14:43
by admin
TheQwerty wrote:admin wrote:Currently you cannot do it with XY. But I'll add it. I probably add 2 or 3 new variables of the form <item1>, <item2>, <item3>. Item 1 is always the focused one, and item 2 is the next one (in the current list order), etc.
I had wanted to request something similar but couldn't think of a good way to do this. That sounds like it will work fine but might be a tad confusing to new users.
Slightly off topic, could we get a variable <path> (or similar) which contains the current working path regardless of selection? (Or does one already exist?)
<curpath>
If you have a less confusing way...

Posted: 19 Nov 2007 17:37
by TheQwerty
admin wrote:<curpath>
Awesome! Are these all documented somewhere?
admin wrote:If you have a less confusing way...

Unfortunately, not really. That will work perfectly for the advanced users, and I'm not sure you need to worry about new users (UDC is an advanced feature after all).
One thought I originally had was to include a way for the user to create a UDC that when run would display a dialog listing the selected files and giving the user the ability to change the order.
A more universal idea was to extend the Clipboard functionality so it was more of a collection utility. Include the ability to ap-/pre-pend selected files to the clipboard as well as remove them. Additionally the user can use the Files on Clipboard LM. (This is something I'd like to see eventually regardless of use in UDCs.)
In either case use some set of numbered variables like <item1> ... <itemX> in the manner you were already thinking. For the latter, there could even be a <ClippedItems> that is just like <items> but uses the clipboard instead of selection.
In the end, I just felt that it was all coming down to being a lot more complicated for you to code with not a lot of gain for the users.
What you suggest is probably the best compromise between the two.
Posted: 19 Nov 2007 18:40
by admin
TheQwerty wrote:admin wrote:<curpath>
Awesome! Are these all documented somewhere?
Click the "Tips..." button in UDC dialog...
TheQwerty wrote:admin wrote:If you have a less confusing way...

Unfortunately, not really. That will work perfectly for the advanced users, and I'm not sure you need to worry about new users (UDC is an advanced feature after all).
One thought I originally had was to include a way for the user to create a UDC that when run would display a dialog listing the selected files and giving the user the ability to change the order.
A more universal idea was to extend the Clipboard functionality so it was more of a collection utility. Include the ability to ap-/pre-pend selected files to the clipboard as well as remove them. Additionally the user can use the Files on Clipboard LM. (This is something I'd like to see eventually regardless of use in UDCs.)
In either case use some set of numbered variables like <item1> ... <itemX> in the manner you were already thinking. For the latter, there could even be a <ClippedItems> that is just like <items> but uses the clipboard instead of selection.
In the end, I just felt that it was all coming down to being a lot more complicated for you to code with not a lot of gain for the users.
What you suggest is probably the best compromise between the two.
<ClippedItems> is an idea, although I'm a bit hesitating: the clipboard is a shared and hidden object. Who knows what's on there? I personally would be very careful depending on the command.
BTW: What I will add soon are variables that open a prompt, like <getfile> or <getnewname>.
Interactive UDCs - the next logical step.
Posted: 19 Nov 2007 18:59
by bergfex
admin wrote:What I will add soon are variables that open a prompt, like <getfile> or <getnewname>. Interactive UDCs - the next logical step.
Wow, it gets better and better...
