Page 1 of 1

Editing graphs in VBA Excel at design time

Posted: Sat Mar 27, 2021 2:37 pm
by 16690880
Hi!

I've been using tchart activex since version 8 in VB6 enviroment and now have to migrate some graphs to Excel under VBA. It is not a big deal to do that, but I'm relizing that I can't edit the graph at design time.

In VB6 environment, right click on tchart control pops up a menu with the edit option that invokes the edit dialog, so you can add series and configure your graph using the dialog. I'm trying to do the same action on VBA for Excel but although there is a pop up menu, when you rigth click the tchart control it does not have the edit option.

Is this control behavior expected under VBA under Excel, or I did a mistake in the installation, or the edit dialog is available through other procedure. I'm using Excel 2013 under Windows 10.

Does anybody have the answer ..?



Thanks,

QuijoteMx

Re: Editing graphs in VBA Excel at design time

Posted: Thu Apr 01, 2021 11:20 am
by yeray
Hello,

Please make sure you have the "design mode" activated in Excel:
2021-04-01_13-19-35.png
2021-04-01_13-19-35.png (70.2 KiB) Viewed 40509 times
Then you should be able to open the options menu right-clicking on the chart.

Re: Editing graphs in VBA Excel at design time

Posted: Fri Apr 02, 2021 3:57 pm
by 15049124
Hi!
Thank you Yeray.

I followed your hint and works perfectly for embedded graphs on Excel sheets.

Sorry, but what I was trying to do is editing graphs on user forms in vba.

I turned on the developers mode prior to trying to edit graphs in user forms without success.

This functionality is what I'm looking for. As you can see, the developers button is turned on but no edit option appears in the pop up menu of the tchart control.

Is there something wrong with my software installation, or I'm not looking in the right place ...?

Re: Editing graphs in VBA Excel at design time

Posted: Tue Apr 06, 2021 11:18 am
by yeray
Hello,

You can open the editor through the properties:
usercontrol.png
usercontrol.png (77.09 KiB) Viewed 40421 times

Re: Editing graphs in VBA Excel at design time

Posted: Tue Apr 06, 2021 8:37 pm
by 15049124
Thank you Yeray ...