Jump to content
Software FX Community

Error with CrosstabSetting as datasource


User (Legacy)

Recommended Posts

I execute the following peice of code:

Dim dtp

Set dtp = Server.CreateObject("ChartFX.ASP.AdoDataProvider")

dtp.ResultSet = RS

'CrossTab Settings

Dim xdp

Set xdp = Server.CreateObject("ChartFX.ASP.CrosstabProvider")

xdp.DataType.Item(0) = CrosstabDataType_RowHeading

xdp.DataType.Item(1) = CrosstabDataType_RowHeading

xdp.DataType.Item(2) = CrosstabDataType_ColumnHeading

xdp.DataType.Item(3) = CrosstabDataType_Value

xdp.DataSource = dtp

xdp.Separator = " "

chart.DataSourceSettings.DataSource = xdp

'Render Chart as ActiveX

Response.Write(chart.GetHtmlTag("800", "400", "ActiveX"))

But when I run it, I get the following error:

Microsoft VBScript runtime (0x800A01FB)

An exception occurred: 'DataSourceSettings.DataSource'

and points to the line:

chart.DataSourceSettings.DataSource = xdp

What am I doing wrong?

Link to comment
Share on other sites

I execute the following peice of code:

Dim dtp

Set dtp = Server.CreateObject("ChartFX.ASP.AdoDataProvider")

dtp.ResultSet = RS

'CrossTab Settings

Dim xdp

Set xdp = Server.CreateObject("ChartFX.ASP.CrosstabProvider")

xdp.DataType.Item(0) = CrosstabDataType_RowHeading

xdp.DataType.Item(1) = CrosstabDataType_RowHeading

xdp.DataType.Item(2) = CrosstabDataType_ColumnHeading

xdp.DataType.Item(3) = CrosstabDataType_Value

xdp.DataSource = dtp

xdp.Separator = " "

chart.DataSourceSettings.DataSource = xdp

'Render Chart as ActiveX

Response.Write(chart.GetHtmlTag("800", "400", "ActiveX"))

But when I run it, I get the following error:

Microsoft VBScript runtime (0x800A01FB)

An exception occurred: 'DataSourceSettings.DataSource'

and points to the line:

chart.DataSourceSettings.DataSource = xdp

What am I doing wrong?

Link to comment
Share on other sites

  • 3 weeks later...

Please post a sample of your resultset RS, indicating the column types. Have 

you tried using a single RowHeading column instead of two?

---

IG

Software FX

"Codex Twin" <codex@more.com> wrote in message

news:0TGEJo0JGHA.476@webserver3.softwarefx.com...

>I execute the following peice of code:

>

> Dim dtp

> Set dtp = Server.CreateObject("ChartFX.ASP.AdoDataProvider")

> dtp.ResultSet = RS

>

> 'CrossTab Settings

> Dim xdp

> Set xdp = Server.CreateObject("ChartFX.ASP.CrosstabProvider")

> xdp.DataType.Item(0) = CrosstabDataType_RowHeading

> xdp.DataType.Item(1) = CrosstabDataType_RowHeading

> xdp.DataType.Item(2) = CrosstabDataType_ColumnHeading

> xdp.DataType.Item(3) = CrosstabDataType_Value

> xdp.DataSource = dtp

> xdp.Separator = " "

>

> chart.DataSourceSettings.DataSource = xdp

>

> 'Render Chart as ActiveX

> Response.Write(chart.GetHtmlTag("800", "400", "ActiveX"))

>

>

> But when I run it, I get the following error:

> Microsoft VBScript runtime (0x800A01FB)

> An exception occurred: 'DataSourceSettings.DataSource'

>

> and points to the line:

> chart.DataSourceSettings.DataSource = xdp

>

> What am I doing wrong?

>

>

Link to comment
Share on other sites

Please post a sample of your resultset RS, indicating the column types. Have 

you tried using a single RowHeading column instead of two?

---

IG

Software FX

"Codex Twin" <codex@more.com> wrote in message

news:0TGEJo0JGHA.476@webserver3.softwarefx.com...

>I execute the following peice of code:

>

> Dim dtp

> Set dtp = Server.CreateObject("ChartFX.ASP.AdoDataProvider")

> dtp.ResultSet = RS

>

> 'CrossTab Settings

> Dim xdp

> Set xdp = Server.CreateObject("ChartFX.ASP.CrosstabProvider")

> xdp.DataType.Item(0) = CrosstabDataType_RowHeading

> xdp.DataType.Item(1) = CrosstabDataType_RowHeading

> xdp.DataType.Item(2) = CrosstabDataType_ColumnHeading

> xdp.DataType.Item(3) = CrosstabDataType_Value

> xdp.DataSource = dtp

> xdp.Separator = " "

>

> chart.DataSourceSettings.DataSource = xdp

>

> 'Render Chart as ActiveX

> Response.Write(chart.GetHtmlTag("800", "400", "ActiveX"))

>

>

> But when I run it, I get the following error:

> Microsoft VBScript runtime (0x800A01FB)

> An exception occurred: 'DataSourceSettings.DataSource'

>

> and points to the line:

> chart.DataSourceSettings.DataSource = xdp

>

> What am I doing wrong?

>

>

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...