I believe you could set that up with dispatch. (we don't have it turned on here, so I can't test).
there is also a recently added command to "set revision" that may help you out as well.
There is no option to manually set variables on transitions.
You should be able to set up your transition to pull the revision variable from the file property. Then you should then be able to use the inc revision command to set the local revision to match the revision variable.
The set revision function has to be done on a state where the revision is configured. It sets the local revision to whatever you select.
Then select a file in that state and click Modify --> Set Revision
You can then select the revision from the dropdown list. Make sure you select the "Update Variable" option if you want the Revision variable to match the Local Revision counter.
You should end up with matching revisions.
If you try to set the revision on a file in a state that does not have the revision setup it won't give you any options.
In this example it doesn't let me do anything for the drawing while the assembly lets me select the revision it is currently set to.
That file is in a state with the revision setup like this, it has the revision and revision variable selected but no increment to reset values.
You can't run set revision during a transition.
Thanks. I am somewhat new to EPDM administration, so I am still trying to learn. I did not know about the Set Revision command. I think that will work for some of my files, but not all of them. I was hoping to be able to clean up our workflow, but it sounds like I may not be able to until I learn a little more about how everything works.
Thanks. We do have Dispatch installed, but I don't know how to use it. The Set Revision command may be what I need to do. I did not know of that before reading the replies to my message.
Is there a way to have a transition that prompts for a user input to set a variable?
As far as I know, it's not possible by default. In order to get a 100% solution, I suggest an add-in adapted to your needs.
If a 90% solution is enough, you can go this way. This example uses VBScript, but it also works in other languages.
-Create a new Transition Action in which the variable has to be set.
-Replace <your extension> with the file extension for which this transition is valid.
-Replace <full script name> with the name of the following script to be executed in this transition.
Customise the script between <VBScript> and </VBScript> to your needs and save it as *.vbs.
Replace <your vault> with your vault.
Replace <your variable> with your variable.
Set objRegEx = CreateObject("VBScript.RegExp") objRegEx.Global = True objRegEx.IgnoreCase = True objRegEx.Pattern = WScript.Arguments(0) fileName = WScript.Arguments(0) folderName = objRegEx.Replace(WScript.Arguments(1), "") Do revNo = InputBox ("Please enter the Revision No.:") If revNo = "" Then Wscript.Echo "You have to enter a Revision No." Else Exit Do End If Loop set vault = createobject("conisiolib.edmvault") vault.loginauto "<your vault>", 0 set folder = vault.GetFolderFromPath(folderName) set filePos = folder.GetFirstFilePosition() do while filePos.isnull = false set file = folder.GetNextFile(filePos) if (file.Name = fileName) then exit do end if loop file.LockFile folder.ID, 0 set fileVar = file.GetEnumeratorVariable("") fileVar.SetVar "<your variable>", "", revNo fileVar.CloseFile(1) file.UnlockFile 0, "Checked in by VBScript"
This example only shows what is at least necessary to solve the problem. Most of the work, the error handling, is missing.