M
MutatedBrain
Hello,
I was trying to program a Org Chart type of application where it
attempts to generate a chart based out of an Excel List. In the chart
I use shapes to show the person names and was wanting to work out a
way in which when the user clicked on the shape, it would pop up the
relevant details about that person (address, contact information,
etc.). I could do this in two ways,
1. Assign the name of the shape which is same as the name of the
person, so when the user clicks on the shape, the Name could be passed
to the form, which in turn would traverse down the list and pick out
the relevant information. Not very elegant.
2. Assign Custom Properties or Tags to each of the Shape so that its
easy to just refer to the shape and get the required information. But
with excel I was unable to work out the tags for the shape or get to
assign custom properties. What do you folks suggest ? Would a custom
class in which shape is object be a good idea ? Since the
application.caller would have the relevant name, i could write a
method to return the object containing the relevant shape ?
I am stuck for direction, I know method 1 is easy to implement, but
somehow I am not very comfortable in working with it. Any suggestions ?
I was trying to program a Org Chart type of application where it
attempts to generate a chart based out of an Excel List. In the chart
I use shapes to show the person names and was wanting to work out a
way in which when the user clicked on the shape, it would pop up the
relevant details about that person (address, contact information,
etc.). I could do this in two ways,
1. Assign the name of the shape which is same as the name of the
person, so when the user clicks on the shape, the Name could be passed
to the form, which in turn would traverse down the list and pick out
the relevant information. Not very elegant.
2. Assign Custom Properties or Tags to each of the Shape so that its
easy to just refer to the shape and get the required information. But
with excel I was unable to work out the tags for the shape or get to
assign custom properties. What do you folks suggest ? Would a custom
class in which shape is object be a good idea ? Since the
application.caller would have the relevant name, i could write a
method to return the object containing the relevant shape ?
I am stuck for direction, I know method 1 is easy to implement, but
somehow I am not very comfortable in working with it. Any suggestions ?