Jump to content

TeeChart for Javascript


lema

Recommended Posts

It is a good approach from Steema, fast and simple ,

but ,

I think that it has some incompatibilities with uniGUI.

(eg. when you want to work with datetime values and include the src\date.format.js ,

it breaks down the uniDateTimePicker)

Link to comment
Share on other sites

  • 1 month later...
  • 2 weeks later...

I've played with the example and I changed this line "'var series=Chart1.addSeries(new Tee.line(Chart1));' +" and I created a graphic Pie , but I can't activate the property "Donut", in Sencha example the form contain a buttom for active this option and one button for save image, how is posible activate these options for this example?

 

Best regards.

Link to comment
Share on other sites

  • 8 months later...

Tip for saving TeeChart for Javascript as Image:

1. Add to example UniHTMLFrame.

2. Edit UniHTMLFrame.HTML property. Insert line:  <img id="img">

3. Add button. OnButtonClick -> UniSession.AddJS('Chart1.toImage("img");');

 

The resulting image can be saved in any browser.

 

 

 

Link to comment
Share on other sites

  • 2 weeks later...

Hi,

 

you can show value of database like that:

 

      .

      . 

      .

     adoquery.active:=True;

 

    while not eof do
       begin
         tmp:=tmp+',"'+IntToStr(Trunc(FieldByName('hiz').AsFloat))+'"';
         next;
         Application.ProcessMessages;
       end;
       tmp:=Copy(tmp,2,length(tmp)-1);
 
     UniSession.AddJS('var querydata = new Array('+tmp+');');
 
 
  UniSession.AddJS(
    'for (var t=0; t<'+IntToStr(ADOQuery.RecordCount)+'; t++) {' +
    'series.data.values[t]=querydata[t];' +
    'series.data.x[t]=t;' +
    '}'
    );
Link to comment
Share on other sites

 

Hi,

 

you can show value of database like that:

 

      .

      . 

      .

     adoquery.active:=True;

 

    while not eof do
       begin
         tmp:=tmp+',"'+IntToStr(Trunc(FieldByName('hiz').AsFloat))+'"';
         next;
         Application.ProcessMessages;
       end;
       tmp:=Copy(tmp,2,length(tmp)-1);
 

     UniSession.AddJS('var querydata = new Array('+tmp+');');
 
 
  UniSession.AddJS(
    'for (var t=0; t<'+IntToStr(ADOQuery.RecordCount)+'; t++) {' +
    'series.data.values[t]=querydata[t];' +
    'series.data.x[t]=t;' +
    '}'
    );

I tried this solution. It works but for large datasets it increases the amount of memory occupied by the program. I'm beginner in Javascript. Maybe there is some way to clear Javascripts?

Link to comment
Share on other sites

  • 8 years later...

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...