Well, the substitution in that case can be done exactly as I described in my previous example - use rexCompile("1T10$") to compile the pattern, and then rexReplace(cellName "" 1) to get the new cellname.
If you have a cellView which has instances from the original library, with the original names, then you'll need to do something like this (this is untested, off-the-top-of-my-head code, just to illustrate the approach)
; expects variables cv to be current cellView, origLibName the name
; of the original library, newLibName the new library
rexCompile("1T10$")
foreach(instHeader cv~>instHeaders
when(instHeader~>libName==origLibName && rexExecute(instHeader~>cellName)
newCellName=rexReplace(instHeader~>cellName "" 1)
dbSetInstHeaderMasterName(instHeader newLibName newCellName instHeader~>viewName)
)
)
Regards,
Andrew.
Originally posted in cdnusers.org by adbeckett