Change Graph Size in Userform

  • Hi Guys,


    I am creating a User Form to automatically generate a chart based on selected data. The problem i am having is that the chart automatically sets itself to a very small window, and does not fill out the Image I have created in the User Form.


    I have added an image to the User Form, and set the image to be automatically populated with the chart based on data the user selects. Could someone tell me what code to input that ensures the image of the chart automatically scales to fit the image window?



    Below is what I continually receive when using the form to create a graph, and the code I have used to auto import the chart as an image to the chart.


    [ATTACH=JSON]{"data-align":"none","data-size":"full","title":"Capture.PNG","data-attachmentid":1207970}[/ATTACH][ATTACH=JSON]{"data-align":"none","data-size":"custom","height":"137","title":"Capture1.PNG","width":"541","data-attachmentid":1207971}[/ATTACH]




    Thank you very much in advance for your help

  • [SIZE=14px]PictureSizeMode Property
    Another property of the image control is the PictureSizeMode.


    If the property is set to the default value 0-frmPictureSizeModeClip the control size can be changed without the picture size being modified. So you can see only part of the picture or there can be a background behind it in a clolor color you can change at will.


    If the property is set to the 1-frmPictureSizeModeStretch the picture is resized as the control is. The image fills the control.


    If the property is set to the 3-frmPictureSizeModeZoom the picture is resized as the control is but the picture and background are present.


    press like if it worked!!![/SIZE]

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!