i need to rename/number all the Branchables in my wire harness. i have a macro that not only FINDS them all, but will select them as well. the problem is that if i echo/query what i have selected with:
msgbox("branch name = " & oSel.item(i).Value.Name)
i do not get what i expect. it doesn't tell me the name/number of the branchable that i selected, instead, the program returns the instance name of the GRANDPARENT of the selected item. when the code runs, that's what gets changed, the instance name of the grandparent. why? i would understand if i had said:
msgbox("branch name = " & oSel.item(i).Value.Parent.Name) or msgbox("branch name = " & oSel.item(i).Value.Parent.Parent.Name)
but i am trying to change the item i SELECTED! there is some talk that even though i can do it manually by going in to the Properties form, it cannot be done with a macro. this makes no sense. also, in the object browser, there is no listing for 'Branchable'. no amount of rewriting will get me the result i need. HELP!
jewely
see pic
msgbox("branch name = " & oSel.item(i).Value.Name)
i do not get what i expect. it doesn't tell me the name/number of the branchable that i selected, instead, the program returns the instance name of the GRANDPARENT of the selected item. when the code runs, that's what gets changed, the instance name of the grandparent. why? i would understand if i had said:
msgbox("branch name = " & oSel.item(i).Value.Parent.Name) or msgbox("branch name = " & oSel.item(i).Value.Parent.Parent.Name)
but i am trying to change the item i SELECTED! there is some talk that even though i can do it manually by going in to the Properties form, it cannot be done with a macro. this makes no sense. also, in the object browser, there is no listing for 'Branchable'. no amount of rewriting will get me the result i need. HELP!
jewely
see pic