Jump to content
Software FX Community

Creating a custom Y scale for a chart does not work why???


User (Legacy)

Recommended Posts

From: "Eric Harris" <ericblahdeblah@hotmail.com>

Subject: Creating a custom Y scale for a chart does not work why???

Date: Tue, 18 Jun 2002 23:55:15 +0100

Lines: 2654

X-Priority: 3

X-MSMail-Priority: Normal

X-Newsreader: Microsoft Outlook Express 6.00.2600.0000

X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000

Message-ID: <ZCKhMtxFCHA.2696@webserver1.softwarefx.com>

Newsgroups: chartfx.internet.55

Path: webserver1.softwarefx.com

Xref: webserver1.softwarefx.com chartfx.internet.55:1059

NNTP-Posting-Host: pc-62-30-120-183-cr.blueyonder.co.uk 62.30.120.183

Hello!

I have the chart below, which I have tried to create a custom Y axis scale

for. This chart only shows 3 out of the 21 labels I want to show, 1 10 and

20, shown in the "only 3 showing" picture attached to this post.. I have

tried to set TestChart.Axis(0).Step=1 after assigning all of the labels for

the axis, this results in the "All Crushed" picture attached to this post.

What am I doing wrong? Why are the labels not going all of the way up the Y

axis?

<html>

<head>

<title>Untitled Document</title>

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

</head>

<body bgcolor="#FFFFFF" text="#000000">

<OBJECT CLASSID="CLSID:21F49842-BFA9-11d2-A89C-00104B62BDDA")

TYPE="application/x-oleobject"

WIDTH=500 HEIGHT=800 ID="TestChart"

CODEBASE=/download/CfxIEAx.cab#Version=4,4,11,3>

<PARAM NAME="LICENSE" VALUE="/license/CfxIE.lic">

</OBJECT>

<SCRIPT LANGUAGE="JAVASCRIPT">

TestChart.OpenDataEx(1,2,-1);

TestChart.ValueEx(0,0)=12.2;

TestChart.ValueEx(0,1)=24.5;

TestChart.ValueEx(0,2)=330;

TestChart.ValueEx(0,3)=11.9;

TestChart.ValueEx(0,4)=23.8;

TestChart.ValueEx(0,5)=343;

TestChart.ValueEx(0,6)=11.7;

TestChart.ValueEx(0,7)=11.4;

TestChart.ValueEx(0,8)=23.2;

TestChart.ValueEx(0,9)=23.4;

TestChart.ValueEx(0,10)=353;

TestChart.ValueEx(0,11)=11.6;

TestChart.ValueEx(0,12)=11.4;

TestChart.ValueEx(0,13)=15.5;

TestChart.ValueEx(0,14)=15;

TestChart.ValueEx(0,15)=355;

TestChart.ValueEx(0,16)=11.7;

TestChart.ValueEx(0,17)=11.8;

TestChart.ValueEx(0,18)=15.5;

TestChart.ValueEx(0,19)=15.3;

TestChart.ValueEx(0,20)=352;

TestChart.ValueEx(0,21)=12;

TestChart.ValueEx(0,22)=127.1;

TestChart.ValueEx(0,23)=347;

TestChart.ValueEx(0,24)=45;

TestChart.ValueEx(0,25)=11.3;

TestChart.ValueEx(0,26)=23.4;

TestChart.ValueEx(0,27)=373;

TestChart.ValueEx(0,28)=11.4;

TestChart.ValueEx(0,29)=23.6;

TestChart.ValueEx(0,30)=360;

TestChart.ValueEx(1,0)=12.8;

TestChart.ValueEx(1,1)=26.6;

TestChart.ValueEx(1,2)=146.7;

TestChart.ValueEx(1,3)=13.2;

TestChart.ValueEx(1,4)=27.2;

TestChart.ValueEx(1,5)=147;

TestChart.ValueEx(1,6)=12.2;

TestChart.ValueEx(1,7)=12.2;

TestChart.ValueEx(1,8)=16.6;

TestChart.ValueEx(1,9)=135.8;

TestChart.ValueEx(1,10)=12.6;

TestChart.ValueEx(1,11)=17.3;

TestChart.ValueEx(1,12)=134.8;

TestChart.ValueEx(1,13)=12.4;

TestChart.ValueEx(1,14)=25.5;

TestChart.ValueEx(1,15)=141.8;

TestChart.ValueEx(1,16)=12.4;

TestChart.ValueEx(1,17)=24.8;

TestChart.ValueEx(1,18)=132.6;

TestChart.ValueEx(1,19)=12.1;

TestChart.ValueEx(1,20)=23.8;

TestChart.ValueEx(1,21)=373.5;

TestChart.CloseData(1)

TestChart.Axis(0).Title="Y Axis";

TestChart.Axis(0).Label(0)=12.8;

TestChart.Axis(0).Label(1)=26.6;

TestChart.Axis(0).Label(2)=36.7;

TestChart.Axis(0).Label(3)=43.2;

TestChart.Axis(0).Label(4)=57.2;

TestChart.Axis(0).Label(5)=77;

TestChart.Axis(0).Label(6)=78.2;

TestChart.Axis(0).Label(7)=112.2;

TestChart.Axis(0).Label(8)=116.6;

TestChart.Axis(0).Label(9)=135.8;

TestChart.Axis(0).Label(10)=152.6;

TestChart.Axis(0).Label(11)=171.3;

TestChart.Axis(0).Label(12)=234.8;

TestChart.Axis(0).Label(13)=250.4;

TestChart.Axis(0).Label(14)=251.5;

TestChart.Axis(0).Label(15)=261.8;

TestChart.Axis(0).Label(16)=262.4;

TestChart.Axis(0).Label(17)=272.8;

TestChart.Axis(0).Label(18)=300.6;

TestChart.Axis(0).Label(19)=330.1;

TestChart.Axis(0).Label(20)=340.8;

TestChart.Axis(0).Label(21)=373.5;

TestChart.Title(2)="Sample Chart"

</SCRIPT>

</html>

Cheers

Eric

Link to comment
Share on other sites

  • 1 month later...

From: "SFX Tech Support" <support@softwarefx.com>

References: <ZCKhMtxFCHA.2696@webserver1.softwarefx.com>

Subject: Re: Creating a custom Y scale for a chart does not work why???

Date: Mon, 22 Jul 2002 16:15:50 -0400

Lines: 137

X-Priority: 3

X-MSMail-Priority: Normal

X-Newsreader: Microsoft Outlook Express 6.00.2600.0000

X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000

Message-ID: <25jiSybMCHA.1280@webserver1.softwarefx.com>

Newsgroups: chartfx.internet.55

Path: webserver1.softwarefx.com

Xref: webserver1.softwarefx.com chartfx.internet.55:1104

NNTP-Posting-Host: JUSTIN2K 198.172.137.89

Hello,

The best way to do something like this is to manually set the Min, Max and

Step properties yourself. Then you should pass the labels with an index

that is the same as your step. For example: If you set a step of 10 along

the y-axis then you would pass your y-axis labels like so:

TestChart.Axis(0).Label(0)= "Label 1"

TestChart.Axis(0).Label(9)= "Label 2"

TestChart.Axis(0).Label(19)= "Label 3"

Justin Trask

Tech. Support

561-392-2023

"Eric Harris" <ericblahdeblah@hotmail.com> wrote in message

news:ZCKhMtxFCHA.2696@webserver1.softwarefx.com...

> Hello!

>

> I have the chart below, which I have tried to create a custom Y axis scale

> for. This chart only shows 3 out of the 21 labels I want to show, 1 10

and

> 20, shown in the "only 3 showing" picture attached to this post.. I have

> tried to set TestChart.Axis(0).Step=1 after assigning all of the labels

for

> the axis, this results in the "All Crushed" picture attached to this post.

> What am I doing wrong? Why are the labels not going all of the way up the

Y

> axis?

>

> <html>

> <head>

> <title>Untitled Document</title>

> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

> </head>

>

> <body bgcolor="#FFFFFF" text="#000000">

>

> <OBJECT CLASSID="CLSID:21F49842-BFA9-11d2-A89C-00104B62BDDA")

> TYPE="application/x-oleobject"

> WIDTH=500 HEIGHT=800 ID="TestChart"

> CODEBASE=/download/CfxIEAx.cab#Version=4,4,11,3>

> <PARAM NAME="LICENSE" VALUE="/license/CfxIE.lic">

> </OBJECT>

> <SCRIPT LANGUAGE="JAVASCRIPT">

> TestChart.OpenDataEx(1,2,-1);

> TestChart.ValueEx(0,0)=12.2;

> TestChart.ValueEx(0,1)=24.5;

> TestChart.ValueEx(0,2)=330;

> TestChart.ValueEx(0,3)=11.9;

> TestChart.ValueEx(0,4)=23.8;

> TestChart.ValueEx(0,5)=343;

> TestChart.ValueEx(0,6)=11.7;

> TestChart.ValueEx(0,7)=11.4;

> TestChart.ValueEx(0,8)=23.2;

> TestChart.ValueEx(0,9)=23.4;

> TestChart.ValueEx(0,10)=353;

> TestChart.ValueEx(0,11)=11.6;

> TestChart.ValueEx(0,12)=11.4;

> TestChart.ValueEx(0,13)=15.5;

> TestChart.ValueEx(0,14)=15;

> TestChart.ValueEx(0,15)=355;

> TestChart.ValueEx(0,16)=11.7;

> TestChart.ValueEx(0,17)=11.8;

> TestChart.ValueEx(0,18)=15.5;

> TestChart.ValueEx(0,19)=15.3;

> TestChart.ValueEx(0,20)=352;

> TestChart.ValueEx(0,21)=12;

> TestChart.ValueEx(0,22)=127.1;

> TestChart.ValueEx(0,23)=347;

> TestChart.ValueEx(0,24)=45;

> TestChart.ValueEx(0,25)=11.3;

> TestChart.ValueEx(0,26)=23.4;

> TestChart.ValueEx(0,27)=373;

> TestChart.ValueEx(0,28)=11.4;

> TestChart.ValueEx(0,29)=23.6;

> TestChart.ValueEx(0,30)=360;

> TestChart.ValueEx(1,0)=12.8;

> TestChart.ValueEx(1,1)=26.6;

> TestChart.ValueEx(1,2)=146.7;

> TestChart.ValueEx(1,3)=13.2;

> TestChart.ValueEx(1,4)=27.2;

> TestChart.ValueEx(1,5)=147;

> TestChart.ValueEx(1,6)=12.2;

> TestChart.ValueEx(1,7)=12.2;

> TestChart.ValueEx(1,8)=16.6;

> TestChart.ValueEx(1,9)=135.8;

> TestChart.ValueEx(1,10)=12.6;

> TestChart.ValueEx(1,11)=17.3;

> TestChart.ValueEx(1,12)=134.8;

> TestChart.ValueEx(1,13)=12.4;

> TestChart.ValueEx(1,14)=25.5;

> TestChart.ValueEx(1,15)=141.8;

> TestChart.ValueEx(1,16)=12.4;

> TestChart.ValueEx(1,17)=24.8;

> TestChart.ValueEx(1,18)=132.6;

> TestChart.ValueEx(1,19)=12.1;

> TestChart.ValueEx(1,20)=23.8;

> TestChart.ValueEx(1,21)=373.5;

> TestChart.CloseData(1)

> TestChart.Axis(0).Title="Y Axis";

> TestChart.Axis(0).Label(0)=12.8;

> TestChart.Axis(0).Label(1)=26.6;

> TestChart.Axis(0).Label(2)=36.7;

> TestChart.Axis(0).Label(3)=43.2;

> TestChart.Axis(0).Label(4)=57.2;

> TestChart.Axis(0).Label(5)=77;

> TestChart.Axis(0).Label(6)=78.2;

> TestChart.Axis(0).Label(7)=112.2;

> TestChart.Axis(0).Label(8)=116.6;

> TestChart.Axis(0).Label(9)=135.8;

> TestChart.Axis(0).Label(10)=152.6;

> TestChart.Axis(0).Label(11)=171.3;

> TestChart.Axis(0).Label(12)=234.8;

> TestChart.Axis(0).Label(13)=250.4;

> TestChart.Axis(0).Label(14)=251.5;

> TestChart.Axis(0).Label(15)=261.8;

> TestChart.Axis(0).Label(16)=262.4;

> TestChart.Axis(0).Label(17)=272.8;

> TestChart.Axis(0).Label(18)=300.6;

> TestChart.Axis(0).Label(19)=330.1;

> TestChart.Axis(0).Label(20)=340.8;

> TestChart.Axis(0).Label(21)=373.5;

> TestChart.Title(2)="Sample Chart"

> </SCRIPT>

>

> </html>

>

> Cheers

>

> Eric

>

>

>

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...