Click here to Skip to main content
15,867,568 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I need to know how to get the shape information(properties, label, values, prompts, etc.) and/or External data information of a shape) using c#. Need help on this...




Thanks,
Saran
Posted
Updated 16-Jul-18 1:11am

(1)this[^]and (2)this[^]will help you.
 
Share this answer
 
Try using this

short iRow = (short)VisRowIndices.visRowFirst;

                // While there are stil rows to look at.
                while (shape.get_CellsSRCExists((short)VisSectionIndices.visSectionProp, iRow, (short)VisCellIndices.visCustPropsValue, (short)0) != 0)
                {
                    // Get the label and value of the current property.
                    string label = shape.get_CellsSRC(
                                          (short)VisSectionIndices.visSectionProp,
                                          iRow,
                                          (short)VisCellIndices.visCustPropsLabel
                                          ).get_ResultStr(VisUnitCodes.visNoCast);

                    string value = shape.get_CellsSRC(
                                           (short)VisSectionIndices.visSectionProp,
                                           iRow,
                                           (short)VisCellIndices.visCustPropsValue
                                           ).get_ResultStr(VisUnitCodes.visNoCast);

                    string strProperties = shape.Name + " - " + label + " - " + value;

                    Console.WriteLine(strProperties);

                    // Move to the next row in the properties
                    iRow++;
                }
 
Share this answer
 
Comments
CHill60 16-Jul-18 7:31am    
The question was asked and answered over seven years ago!
Just copying someone else's code from another site without any credit is plagiarism and will not be tolerated on this site.
Stick to answering new questions where the OP still needs help, and if you find code elsewhere that is appropriate include a link to the original

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900