Q:

Excel VBA Userform - Setting a chart the same size as userform image

I have an image in a userform which displays a pre-existing chart, according the properties menu the height = 246 and width = 462 (it does not specify units).  I want my chart to be sized so that when a .GIF of the chart is saved and loaded to the userform image is matches the dimensions.  In the chart properties I can change the dimensions but only has the option for inches.  How can I get these dimensions to match?

A:

If you are using an Image control to display the chart, then size the image control to fit the userform as per your requirements and then set the "PictureSizeMode" property of the image control to "fmPictureSizeModeStretch".

