Jump to content
Software FX Community

Error while refreshing WebForm with Maps Extension.


User (Legacy)

Recommended Posts

I am running ChartFX 6.2 Dev Studio, and loading the Map with some 

conditional attributes and data from a DB. This works just fine if I run the

page the very first time. However, simply doing a refresh fails with the

following error:

Description: An unhandled exception occurred during the execution of the

current web request. Please review the stack trace for more information

about the error and where it originated in the code.

Exception Details: System.IndexOutOfRangeException: Index was outside the

bounds of the array.

Source Error:

Line 94: if (ds.Tables.Count > 0)

Line 95: {

Line 96: map.DataSource = ds.Tables[0];

Line 97: map.Recalculate();

Line 98: }

Source File: c:\inetpub\wwwroot\geodemo\geodemo.aspx.cs Line: 96

Stack Trace:

[indexOutOfRangeException: Index was outside the bounds of the array.]

SoftwareFX.ChartFX.Internet.Server.DataArray.get_Item(Int32 index) +19

SoftwareFX.ChartFX.Internet.Server.Condition.GS(Int32 1QJ, Int32 1QK,

IData 1QL) +199

SoftwareFX.ChartFX.Internet.Server.ConditionalAttributes.GU(Int32 1QP,

Int32 1QQ, IData 1QR) +43

SoftwareFX.ChartFX.Internet.Server.ConditionalAttributesCollection.GX(ConditionalAttributesEventArgs

1QV) +108

SoftwareFX.ChartFX.Internet.Server.ConditionalAttributesCollection.GY(Int32

1QW, Int32 1QX) +89

SoftwareFX.ChartFX.Internet.Server.1E.FitNewValue(Int32 nSeries, Int32

nPoint, COD nChannel, Double dValue) +90

SoftwareFX.ChartFX.Internet.Server.DataArray.set_Item(Int32 series, Int32

point, Double value) +131

SoftwareFX.ChartFX.Internet.Server.DataSourceSettings.2J() +2308

SoftwareFX.ChartFX.Internet.Server.DataSourceSettings.2I(Boolean 0OO) +57

SoftwareFX.ChartFX.Internet.Server.DataSourceSettings.set_DataSource(Object

value) +269

SoftwareFX.ChartFX.Internet.Server.ChartCore.set_DataSource(Object value)

+55

GeoDemo.GeoDemo.btnRefresh_Click(Object sender, EventArgs e) in

c:\inetpub\wwwroot\geodemo\geodemo.aspx.cs:96

System.Web.UI.WebControls.Button.OnClick(EventArgs e) +108

System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String

eventArgument) +57

System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler

sourceControl, String eventArgument) +18

System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33

System.Web.UI.Page.ProcessRequestMain() +1292

Any Suggestions?

Thanks!

Sanjay.

Link to comment
Share on other sites

Dear Sanjay,

I suspect the data in the ds.Tables[0] has no rows

Using the debugger please check their is actually REAL data in your table?

Has the structure changed?

Also, if you run the same code with a Bar Chart (not a map) do you get the

same error?

This means delete the map and drop a chart and run the same code on a chart

not a map.

You could just set the gallery of the map to be bar and you would achieve a

similar result.

If you still think there is a problem attach a case that I can reproduce,

or, email support AT softwarefx dot com with your case and put it to my

attention, Charles.

-c

"sanjay ramaswamy" <sanjayhr@hotmail.com> wrote in message

news:UrHdL6HrFHA.1992@webserver3.softwarefx.com...

>I am running ChartFX 6.2 Dev Studio, and loading the Map with some

>conditional attributes and data from a DB. This works just fine if I run

>the page the very first time. However, simply doing a refresh fails with

>the following error:

>

> Description: An unhandled exception occurred during the execution of the

> current web request. Please review the stack trace for more information

> about the error and where it originated in the code.

>

> Exception Details: System.IndexOutOfRangeException: Index was outside the

> bounds of the array.

>

> Source Error:

>

>

> Line 94: if (ds.Tables.Count > 0)

> Line 95: {

> Line 96: map.DataSource = ds.Tables[0];

> Line 97: map.Recalculate();

> Line 98: }

>

>

> Source File: c:\inetpub\wwwroot\geodemo\geodemo.aspx.cs Line: 96

>

> Stack Trace:

>

>

> [indexOutOfRangeException: Index was outside the bounds of the array.]

> SoftwareFX.ChartFX.Internet.Server.DataArray.get_Item(Int32 index) +19

> SoftwareFX.ChartFX.Internet.Server.Condition.GS(Int32 1QJ, Int32 1QK,

> IData 1QL) +199

> SoftwareFX.ChartFX.Internet.Server.ConditionalAttributes.GU(Int32 1QP,

> Int32 1QQ, IData 1QR) +43

>

> SoftwareFX.ChartFX.Internet.Server.ConditionalAttributesCollection.GX(ConditionalAttributesEventArgs

> 1QV) +108

>

> SoftwareFX.ChartFX.Internet.Server.ConditionalAttributesCollection.GY(Int32

> 1QW, Int32 1QX) +89

> SoftwareFX.ChartFX.Internet.Server.1E.FitNewValue(Int32 nSeries, Int32

> nPoint, COD nChannel, Double dValue) +90

> SoftwareFX.ChartFX.Internet.Server.DataArray.set_Item(Int32 series,

> Int32 point, Double value) +131

> SoftwareFX.ChartFX.Internet.Server.DataSourceSettings.2J() +2308

> SoftwareFX.ChartFX.Internet.Server.DataSourceSettings.2I(Boolean 0OO)

> +57

>

> SoftwareFX.ChartFX.Internet.Server.DataSourceSettings.set_DataSource(Object

> value) +269

> SoftwareFX.ChartFX.Internet.Server.ChartCore.set_DataSource(Object

> value) +55

> GeoDemo.GeoDemo.btnRefresh_Click(Object sender, EventArgs e) in

> c:\inetpub\wwwroot\geodemo\geodemo.aspx.cs:96

> System.Web.UI.WebControls.Button.OnClick(EventArgs e) +108

>

> System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String

> eventArgument) +57

> System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler

> sourceControl, String eventArgument) +18

> System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33

> System.Web.UI.Page.ProcessRequestMain() +1292

>

>

> Any Suggestions?

> Thanks!

> Sanjay.

>

Link to comment
Share on other sites

Thanks, Charles for your prompt response.

Like I said, I am simply doing a Page refresh (F5 in browser) immediately,

and this is what I get. If I close the browser preview window in VS, and

reload the page, it works fine. So, data does exist.

As per your suggestion, I will try the same with the chart and let you know.

Thanks,

Sanjay.

"Software FX Support" <support@softwarefx.com> wrote in message

news:llc$xSKrFHA.1724@webserver3.softwarefx.com...

> Dear Sanjay,

> I suspect the data in the ds.Tables[0] has no rows

> Using the debugger please check their is actually REAL data in your table?

> Has the structure changed?

>

> Also, if you run the same code with a Bar Chart (not a map) do you get the

> same error?

> This means delete the map and drop a chart and run the same code on a

> chart not a map.

> You could just set the gallery of the map to be bar and you would achieve

> a similar result.

>

> If you still think there is a problem attach a case that I can reproduce,

> or, email support AT softwarefx dot com with your case and put it to my

> attention, Charles.

> -c

>

> "sanjay ramaswamy" <sanjayhr@hotmail.com> wrote in message

> news:UrHdL6HrFHA.1992@webserver3.softwarefx.com...

>>I am running ChartFX 6.2 Dev Studio, and loading the Map with some

>>conditional attributes and data from a DB. This works just fine if I run

>>the page the very first time. However, simply doing a refresh fails with

>>the following error:

>>

>> Description: An unhandled exception occurred during the execution of the

>> current web request. Please review the stack trace for more information

>> about the error and where it originated in the code.

>>

>> Exception Details: System.IndexOutOfRangeException: Index was outside the

>> bounds of the array.

>>

>> Source Error:

>>

>>

>> Line 94: if (ds.Tables.Count > 0)

>> Line 95: {

>> Line 96: map.DataSource = ds.Tables[0];

>> Line 97: map.Recalculate();

>> Line 98: }

>>

>>

>> Source File: c:\inetpub\wwwroot\geodemo\geodemo.aspx.cs Line: 96

>>

>> Stack Trace:

>>

>>

>> [indexOutOfRangeException: Index was outside the bounds of the array.]

>> SoftwareFX.ChartFX.Internet.Server.DataArray.get_Item(Int32 index) +19

>> SoftwareFX.ChartFX.Internet.Server.Condition.GS(Int32 1QJ, Int32 1QK,

>> IData 1QL) +199

>> SoftwareFX.ChartFX.Internet.Server.ConditionalAttributes.GU(Int32 1QP,

>> Int32 1QQ, IData 1QR) +43

>>

>> SoftwareFX.ChartFX.Internet.Server.ConditionalAttributesCollection.GX(ConditionalAttributesEventArgs

>> 1QV) +108

>>

>> SoftwareFX.ChartFX.Internet.Server.ConditionalAttributesCollection.GY(Int32

>> 1QW, Int32 1QX) +89

>> SoftwareFX.ChartFX.Internet.Server.1E.FitNewValue(Int32 nSeries, Int32

>> nPoint, COD nChannel, Double dValue) +90

>> SoftwareFX.ChartFX.Internet.Server.DataArray.set_Item(Int32 series,

>> Int32 point, Double value) +131

>> SoftwareFX.ChartFX.Internet.Server.DataSourceSettings.2J() +2308

>> SoftwareFX.ChartFX.Internet.Server.DataSourceSettings.2I(Boolean 0OO)

>> +57

>>

>> SoftwareFX.ChartFX.Internet.Server.DataSourceSettings.set_DataSource(Object

>> value) +269

>> SoftwareFX.ChartFX.Internet.Server.ChartCore.set_DataSource(Object

>> value) +55

>> GeoDemo.GeoDemo.btnRefresh_Click(Object sender, EventArgs e) in

>> c:\inetpub\wwwroot\geodemo\geodemo.aspx.cs:96

>> System.Web.UI.WebControls.Button.OnClick(EventArgs e) +108

>>

>> System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String

>> eventArgument) +57

>> System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler

>> sourceControl, String eventArgument) +18

>> System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33

>> System.Web.UI.Page.ProcessRequestMain() +1292

>>

>>

>> Any Suggestions?

>> Thanks!

>> Sanjay.

>>

>

>

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...