Chart Object

P

Prabhakar

Friends,

I have been migrating ASP applications from IIS4.0/NT4.0 to
IIS5.0/W2K. All the applications working perfectly except one. This
particular application will make use of asp chart object.




Sub BuildGraph(rate(), name,color,chartHight,chartWidth)
ctBar = 5
cNone = 0
cGradient = 6
'***** Delete old jpg's ****

ON error resume next

rem **********************************************************************
rem * Instantiate the Chart component
rem **********************************************************************
Set Chart = Server.CreateObject ("ASPChart.Chart")
Chart.AddSeries (ctBar)
Chart.VertAxisMax= 100
Chart.VertAxisMin = 90
for i = 1 to 12
if rate(i) <> 0 then
Chart.AddValue rate(i), MonthName(i,TRUE) , color
end if
Next
Chart.BarStyle = cGradient
Chart.LegendVisible = false
Chart.AddAxisLabel 2,name
rem **********************************************************************
rem * Set the PanelColor, remove the OuterBevel
rem **********************************************************************
Chart.PanelColor = vbWhite
Chart.BevelOuter = cNone
Chart.ChartBGColor = vbWhite
rem **********************************************************************
rem * Set the Width and Height of the image
rem **********************************************************************
Chart.Height = chartHight '100
Chart.Width = chartWidth '300
rem **********************************************************************
rem * Set the filename, save the image and write the image tag
rem **********************************************************************
rem dir_path value "d:\inetpub\download"
Chart.FileName = Application("dir_path")& Session.SessionID & name &
".jpg"
Chart.SaveChart
rem **********************************************************************
rem * Destroy the object
rem **********************************************************************
Set Chart = nothing
End sub

This code is in functions_share.asp



The above sub being called from the xyz.asp (located in the same
folder as "download" folder is) as following:


If Session("GRAPH_type")="abc" or Session("GRAPH_type")="def" then
Call BuildGraph(filled_rate,"Chart Name",vbBlue,100,300)



<td><img src="./download/<%=Session.SessionID%>Chart%20Name.jpg"></td>


The problem with the above blocks of codes is " JPG are not created
!". I have given enough permissions to write to "download" folder.
What am I missing here.

Any help in this direction appreciated...
TIA
KP
 
C

Chris Barber

Well - there you go, what more do you need?

Reinstall it with the relevant purchased license keys or check that the
license key applied during use of the component is valid.

Chris.

Error message when use it is
This evaluation component has expired.
thanks
 
C

Chris Barber

Hmm , you may be out of luck unless you can find the original install set or
get ServerObjects to help you (unlikely with unsupported legacy components).

http://www.support.hostinguk.net/components/aspchart.htm

Chris.

Well - there you go, what more do you need?

Reinstall it with the relevant purchased license keys or check that the
license key applied during use of the component is valid.

Chris.

Error message when use it is
This evaluation component has expired.
thanks
 
P

Prabhakar

Hi Chris,

Is there any alternative for building the chart on fly.
Because all my efforts to use the aspchart.dll are
failed. Are there any third party software that I can
make use of to build this graph in jpeg format?

thanks in advance

Prabhakar
 
C

Chris Hohmann

Prabhakar said:
Hi Chris,

Is there any alternative for building the chart on fly.
Because all my efforts to use the aspchart.dll are
failed. Are there any third party software that I can
make use of to build this graph in jpeg format?

thanks in advance

Prabhakar

Is MS Office 2000/XP installed on the Server. If so, you may want to
investigate Office Web Components (OWC). Here's a list of articles about
charting in ASP.

http://www.4guysfromrolla.com/webtech/LearnMore/Graphing.asp

Note: If you have Office XP, a very exciting new feature of OWC is the
ability to stream the gif content directly to the Response object,
eliminating the need to manage the temporary image files. The
documentation for OWC is somewhat sparse so if you decide to use this
approach, please feel free to post follow-up questions here.

HTH
-Chris
 
C

Chris Hohmann

Prabhakar said:
MS-Office 2000 is installed on the server, but not Office
XP.
thanks

Office 2000 is fine. In fact the articles listed in that link reference
OWC for Office 2000.
 
C

Chris Barber

ChartDirector is pretty good (or any other third part chart ASP component).

ChartDirector:
http://www.advsofteng.com/

Since ASPChart is now unsupported you may (with a bit of pleading) be able
to wangle a FOC license from ServerObjects - have you contacted them?

Chris.

Hi Chris,

Is there any alternative for building the chart on fly.
Because all my efforts to use the aspchart.dll are
failed. Are there any third party software that I can
make use of to build this graph in jpeg format?

thanks in advance

Prabhakar
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,094
Messages
2,570,615
Members
47,230
Latest member
RenaldoDut

Latest Threads

Top