TeeChart 1.1.1644.16795 - VS.NET 2003 - AutoPostback

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Dautm
Newbie
Newbie
Posts: 18
Joined: Sat Oct 04, 2003 4:00 am
Location: Dalmine

TeeChart 1.1.1644.16795 - VS.NET 2003 - AutoPostback

Post by Dautm » Wed Jul 21, 2004 9:39 am

Hello, I downloaded the new version of TeeChart.NET and previously working pages now don't work...
The problem is on charts with AutoPostback set to true (TempChart set to Session), if I click on a chart I get the error message: "System.ArgumentException: Invalid parameter used."
while with previous version it was ok.
I'm using VS.NET 2003 with framework Version 1.1.4322.573.

This is the stack trace:
[ArgumentException: Invalid parameter used.]
System.Drawing.Bitmap..ctor(Int32 width, Int32 height, PixelFormat format)
System.Drawing.Bitmap..ctor(Int32 width, Int32 height)
Steema.TeeChart.Chart.Bitmap(Int32 width, Int32 height, PixelFormat pixelformat) +41
Steema.TeeChart.Chart.Bitmap(Int32 width, Int32 height) +11
Steema.TeeChart.Web.WebChart.CreatePictureFile(HtmlTextWriter writer) +511
Steema.TeeChart.Web.WebChart.Render(HtmlTextWriter output) +10
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer)
System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer)
System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer)
System.Web.UI.HtmlControls.HtmlForm.Render(HtmlTextWriter output)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer)
System.Web.UI.Control.Render(HtmlTextWriter writer)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Page.ProcessRequestMain()

Dautm
Newbie
Newbie
Posts: 18
Joined: Sat Oct 04, 2003 4:00 am
Location: Dalmine

Found solution but new problem...

Post by Dautm » Wed Jul 21, 2004 9:44 am

I found that previous error was generated by Height and Width property not assigned (!!!???) but now (as I click on the chart) I get different error message:
"System.NullReferenceException: Object reference not set to an instance of an object."

Stack Trace:
[NullReferenceException: Object reference not set to an instance of an object.]
Steema.TeeChart.Zoom.Draw() +166
Steema.TeeChart.Chart.CheckZoomPanning(MouseEventArgs e) +322
Steema.TeeChart.Chart.DoMouseDown(Boolean IsDoubleClick, MouseEventArgs e) +536
Steema.TeeChart.Web.WebChart.CreatePictureFile(HtmlTextWriter writer) +568
Steema.TeeChart.Web.WebChart.Render(HtmlTextWriter output) +10
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer)
System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer)
System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer)
System.Web.UI.HtmlControls.HtmlForm.Render(HtmlTextWriter output)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer)
System.Web.UI.Control.Render(HtmlTextWriter writer)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Page.ProcessRequestMain()

Marc
Site Admin
Site Admin
Posts: 1266
Joined: Thu Oct 16, 2003 4:00 am
Location: Girona
Contact:

Post by Marc » Mon Jul 26, 2004 4:16 pm

Hello,

This may be related to a general error already recognised in the last release in the zoom draw code (fixed for the next update) though we would not have expected this result.

We'll try and reproduce the symptoms here. Are you able to reproduce the issue with the TeeChart demo WebForm project?

With thanks.
Regards,
Marc Meumann
Steema Support

Dautm
Newbie
Newbie
Posts: 18
Joined: Sat Oct 04, 2003 4:00 am
Location: Dalmine

Post by Dautm » Wed Jul 28, 2004 8:40 am

Hello,
I tried with demo and the chart with AutoPostback (top left) works fine.
I opened the demo project and I did this:
- added WebForm
- added WebChart
- resized WebChart (if not it generates the other error !!!???)
- set AutoPostback to true
- set TempChart to Session
- run the application
- SAME ERROR
- added ClickBackground event and put some dummy code inside
- run the application
- IT WORKS !!!

Can I assume that, with the new release, it's mandatory to write at least one click event (I tried also to leave it without code and it still works) ???
Is there any way to fix this ???

NOTE:
In our applications we don't use any click event since they are processed after PageLoad (it's too late...). Instead we look for "wchValues.x" and "wchValues.y" form values in Request variable to intercept click events (they are available for processing in PageLoad).

Christopher
Site Admin
Site Admin
Posts: 1349
Joined: Thu Jan 01, 1970 12:00 am
Location: Riudellots de la Selva, Catalonia
Contact:

Post by Christopher » Wed Jul 28, 2004 11:32 am

Hi -
Hello,
I tried with demo and the chart with AutoPostback (top left) works fine.
I opened the demo project and I did this:
- added WebForm
- added WebChart
- resized WebChart (if not it generates the other error !!!???)
- set AutoPostback to true
- set TempChart to Session
- run the application
- SAME ERROR
I've just tried this using the WebForm demo, adding in a new WebForm etc. etc. Using v1.1.1644.16795 the application runs error free.

So, what I did was the following:
-Create a brand new WebForm project
-Add a WebChart to the WebForm
-Resize the WebChart
-Set AutoPostback to true
-Set TempChart to Session
-Run the application

under these circumstances I received the same error. The reason for this is explained in "Tutorial 9 - ASP.NET Applications" under the heading "File or Session setting (TempChart property)"; when you set TempChart to Session you need to add GetChart.aspx to the project. Adding this file, shipped with TeeChart for .NET's 'WebForm' example, makes the application run error-free.

Can you reproduce this behaviour at your end with a brand-new WebForm project?
Thank you!

Christopher Ireland (Steema crew)
Please be aware of the newsgroup archives:
http://www.teechart.net/support/search.php
http://groups.google.com
http://codenewsfast.com/

Dautm
Newbie
Newbie
Posts: 18
Joined: Sat Oct 04, 2003 4:00 am
Location: Dalmine

Post by Dautm » Wed Jul 28, 2004 12:24 pm

Since I have a bunch of running applications which are using events on WebChart, OBVIOUSLY, I have already the GetChart.aspx in my projects...

As I described after the row "SAME ERROR" (the last you copy in your reply) I found what is generating the error: the new version wants a Click event (ClickBackground) defined also if not used; if you read my previous reply you will find why and how we intercept click events in other way.

Christopher
Site Admin
Site Admin
Posts: 1349
Joined: Thu Jan 01, 1970 12:00 am
Location: Riudellots de la Selva, Catalonia
Contact:

Post by Christopher » Wed Jul 28, 2004 1:25 pm

Hi --
As I described after the row "SAME ERROR" (the last you copy in your reply) I found what is generating the error: the new version wants a Click event (ClickBackground) defined also if not used; if you read my previous reply you will find why and how we intercept click events in other way.
Until I can reproduce the error here there is little hope of me being able to solve it for you. If you would be so kind, and to speed up the turnaround of this issue, could you please post a WebForm project I can run "as-is" to:
news://www.berneda.com/steema.public.attachments

Many thanks.
Thank you!

Christopher Ireland (Steema crew)
Please be aware of the newsgroup archives:
http://www.teechart.net/support/search.php
http://groups.google.com
http://codenewsfast.com/

Dautm
Newbie
Newbie
Posts: 18
Joined: Sat Oct 04, 2003 4:00 am
Location: Dalmine

Post by Dautm » Wed Jul 28, 2004 1:43 pm

I made the test project for you but, unfortunately, I'm behind a firewall which prevents me to connect to news servers.
Is there another way to send you attachments ?

Pep
Site Admin
Site Admin
Posts: 3296
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Wed Jul 28, 2004 2:05 pm

H,
you can send me it directly to my mail account, pep@steema.com

Post Reply