Hi,
We are currently experiencing some problems when unloading forms that contain TChart controls. We are using TChart in a VB6 environment and we have done nothing in the code other than replace the v6 TChart object with the v8 TChart control object.
Specifically, we have 2 forms loaded (FormA and FormB) each of which contains a TChart control.
FormA has a Form_Unload event which unloads FormB:
...
...
Private Sub Form_Unload(Cancel As Integer)
Unload FormB
End Sub
...
...
If FormB has the focus and we close FormA (by clicking the default Close button at the top right of FormA), FormA's Form_Activate event is triggered during FormA's Form_Unload event.
Previous to upgrading to the v8 TChart control, FormA's Form_Activate event was not triggered for the scenario described above. This has been observed with both TeeChart8.ocx and TeeChart8Langs.ocx
Any assistance would be greatly appreciated.
Thanks,
Ross
Problem when unloading forms containing TChart control
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Ross,
Could you please arrange a simple example project we can run "as-is" to reproduce the problem here?
You can either post your files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.
Thanks in advance.
Could you please arrange a simple example project we can run "as-is" to reproduce the problem here?
You can either post your files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.
Thanks in advance.
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Hi Narcís,
Thanks for your prompt reply. Ross has asked me to provide you with an example project that demonstrates the problem we are experiencing.
I have uploaded an example project to your upload page as directed. The name of the file is FormUnloadBug.zip
If you unzip and run the example project:
1. Click Command1 on the main form to load FormA and FormB (FormB should have the focus)
2. Immediately click the close button at the top left of FormA which is in the background behind FormB
You should get an error message displayed which is related to execution of code within FormA's Form_Activate event. It appears that FormA's Form_Activate event has been triggered whilst in the middle of FormA's Form_Unload event.
This has been observed with both TeeChart8.ocx and TeeChart8Langs.ocx but was not observed with TeeChart6.ocx
Please let me know if you need more information.
Best Regards,
Raymond Oreo
Thanks for your prompt reply. Ross has asked me to provide you with an example project that demonstrates the problem we are experiencing.
I have uploaded an example project to your upload page as directed. The name of the file is FormUnloadBug.zip
If you unzip and run the example project:
1. Click Command1 on the main form to load FormA and FormB (FormB should have the focus)
2. Immediately click the close button at the top left of FormA which is in the background behind FormB
You should get an error message displayed which is related to execution of code within FormA's Form_Activate event. It appears that FormA's Form_Activate event has been triggered whilst in the middle of FormA's Form_Unload event.
This has been observed with both TeeChart8.ocx and TeeChart8Langs.ocx but was not observed with TeeChart6.ocx
Please let me know if you need more information.
Best Regards,
Raymond Oreo
Hi Raymond and Ross,
Yes, you are right. Something strange is happening here. I've added it to the wish list to be investigated asap. (TA05013203)
Yes, you are right. Something strange is happening here. I've added it to the wish list to be investigated asap. (TA05013203)
Best Regards,
Yeray Alonso Development & Support Steema Software Av. Montilivi 33, 17003 Girona, Catalonia (SP) | |
Please read our Bug Fixing Policy |