Excel Chartshape height and datapoints

I recently downloaded a trial version, as we're trying to programmatically duplicate an example Excel file. It contains a chart within the middle of a page of a specific height/width combo, and has data labels of **Value From Cells** of column A. I created a *ChartShape* object, and while the top and left parameters work, I cannot seem to change it's width nor height. I've tried chart.Width as well as chart.ChartObject.Width. The second issue is with the data labels. I can't seem to find where these are created other than looping through the series.DataPoints collection and directly changing the DataLabels.Text parameter, manually figuring out what the text should be, vs what you'd do in Excel with just selecting and filling in **Value From Cells**. The other issue here is that it though I imported data via *ImportArray*, the *DataPoints* collection says it has zero items, so I have to loop through the data array I imported to add to non existing *DataPoints*, rather than just looping through a list of *DataPoints*. I was wondering what the correct way to go about doing this would be.
asked 5/17/2018 5:46:41 PM
add a comment

0 Answers

Your Answer

Not the answer you're looking for? Browse other questions tagged excel or ask your own question.