-
Re: I only want filenames starting with "2" to qualify for a transition
Tom Helsley Aug 21, 2013 2:54 PM (in response to Karen Brunke)Is this for your initial check-in, or a file that is already in a workflow state and is about to go to another state?
-
Re: I only want filenames starting with "2" to qualify for a transition
Karen Brunke Aug 21, 2013 3:02 PM (in response to Tom Helsley)Already in a workflow state, and transitioning to another one.
-
-
Re: I only want filenames starting with "2" to qualify for a transition
Michael Dekoning Aug 21, 2013 3:17 PM (in response to Karen Brunke)I would have thought that would work. Try this
%\[2]%.sld%
-
Re: I only want filenames starting with "2" to qualify for a transition
Karen Brunke Aug 21, 2013 3:20 PM (in response to Michael Dekoning)Still lets it thru if there is a 2 in any of the folder names.
-
Re: I only want filenames starting with "2" to qualify for a transition
Michael Dekoning Aug 21, 2013 3:24 PM (in response to Karen Brunke)Interesting. I'll have to set this up in a test vault and see. What version of EPDM are you running?
-
Re: I only want filenames starting with "2" to qualify for a transition
Karen Brunke Aug 22, 2013 7:58 AM (in response to Michael Dekoning)Version 12.5
-
-
-
-
Re: I only want filenames starting with "2" to qualify for a transition
Tom Helsley Aug 21, 2013 3:29 PM (in response to Karen Brunke)How about this...
"%\2%[^\]%.sld%"
-
Re: I only want filenames starting with "2" to qualify for a transition
Karen Brunke Aug 22, 2013 8:03 AM (in response to Tom Helsley)Nope, but this looks wrong to me. I want only filenames starting with 2, no matter what the path is. What I'm getting is "a 2 anywhere in the entire filename including the path.
-
Re: I only want filenames starting with "2" to qualify for a transition
Jim Sculley Aug 22, 2013 9:57 AM (in response to Karen Brunke)The problem here is that % matches ANYTHING. So if you try to exclude the path separator using [^\], but then follow it with a %, anything will match, including the path separator. If your file names are completely unstructured other than starting with 2, I suspect that there is no way to do this with a transition condition on the file path. You will have to store the file name in a variable and use that in your transition condition.
If there is any structure to your file names, such as always having the same number characters after the 2, or using a limited set of characters, you might be able to come up with a condition value that will match.
Jim S.
-
Re: I only want filenames starting with "2" to qualify for a transition
Karen Brunke Aug 22, 2013 10:32 AM (in response to Jim Sculley)I can do that. It's just an example straight out of the admin guide, so I didn't expect it to be such a pain.
The reason I want to limit the filename is that it will be a new installation. I want people to get in the habbit of putting things in the right folders. In these particular folders, everything should start with the project number that is identified in the folder variables, which always start with 2. However, coding that is cumbersome. Requiring a 2 as the first character should be simple!
-
Re: I only want filenames starting with "2" to qualify for a transition
Jim Sculley Aug 22, 2013 11:15 AM (in response to Karen Brunke)There should be a condition to check the filename without the path, but unfortuantely there isn't.
I have found that relying on people to form good habits often leads to disappointment. Bad habits are far more common. The system I created here gives the users the freedom to name files whatever they want. Each project has a Work In Progress folder where users can create, modify, delete, and rename files to their heart's content. When they have it the way they want it, they 'Release' it via a transition at which point I have an add-in that renames and moves files to appropriate locations with appropriate file names. At the moment, the users are still required to enter part numbers as part of this process and they still make mistakes due to bad habits, but it is far better than it was before we started with EPDM. The next update to the system will automate the part number assignment as well, removing another point of failure.
If you really want to use EPDM to its full potential, I think it is crucial to learn how to write addins (preferrably in C#, not VB). You will have far more power at your fingertips. For example, toy solve your problem with an add-in, all you would need is an EdmCmd_PreState hook looking for files headed for your ISSUED state. The system hands your add-in the names of all files involved. You can use the much more powerful text processing capabilities of C# to get the file name and check to see if it starts with a '2'. If not, you can let the user know and cancel the state change. This probably requires less that 100 lines of code.
-
-
-
-
-
-
Re: I only want filenames starting with "2" to qualify for a transition
Karen Brunke Aug 22, 2013 8:59 AM (in response to Martin Solem)Unfortunately, I'm not on 2013, so I cannot tell you if it will work in 2013. I am beginning to suspect this is a bug. Hopefully they fixed it in 2013.
-
-
Re: I only want filenames starting with "2" to qualify for a transition
Russell Abraham Aug 22, 2013 11:19 AM (in response to Karen Brunke)Karen,
Try taking the % at the begining away because it should then search for files starting with a 2 but find anything else after the 2 but before the file extension.