I'm trying to work with the function SetActionInRevisionManager of the revision manager class.
Its arguments are: SetActionInRevisionManager(nFileCount As Integer, ListOfInputFileNames As Object, ListOfInputActions As Object, Optional ListOfNewFileNames As Object = Nothing, Optional NewFilePathForAllFiles As Object = Nothing)
What i want my program to do is to open the revision manager, let it open an assembly and let it rename every occurence wich has a filename containing xx-xxxx to a drawing number like 99-9999.
I'm able to programatically open the revision manager and open the assembly in the manager with vb.net. the only thing i can't seem to get working is this SetActionInRevisionManager function.
I create three lists:
RenameList:list of strings containing all fileNames i want to rename
RenameAction: list of same size with each element:
RenameToList: list of same size with all new file names
Directory: path of the directory.
Then i call
It doesn't give me an error but nothing changes in the revision manager.
Am i using this function wrongly?
Thanks for your help.
Solved! Go to Solution.
I used this sample as the basis for a very useful application for our company to post-process the file names of a Teamcenter assembly export before sending to our fabricators. It had to be done manually before so thanks a lot for the help!
Thanks a bunch,
I finay got it working.
So the arguments should be inserted as an array instead as a List
Don't you agree it is a little confussing defining the function as following:
Function SetActionInRevisionManager(nFileCount As Integer, ListOfInputFileNames As Object, ListOfInputActions As Object, Optional ListOfNewFileNames As Object = Nothing, Optional NewFilePathForAllFiles As Object = Nothing)
while in fact they should be are arrays instead of lists?
Ps: if you were to visit Belgium one day, remind me to buy you a drink!
You've been helping me out quite some times here and i really appreciate it!
Thanks a bunch!