Something like this? Remember, you can't rename the "Main" representation.
Dim oDoc As Inventor.Document = ThisApplication.ActiveDocument
Dim oCD As ComponentDefinition = oDoc.ComponentDefinition
Dim oPR As PositionalRepresentation = oCD.RepresentationsManager.PositionalRepresentations("OldName")
oPR.Name = "NewName"
Consider using "Accept as Solution" / "Kudos" if you find this helpful.
- - - - - - - - - - - - - - -
Regards,
Mike
"Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live." - John F. Woods