Code: Select all
Query:= TQuery.Create(Self);
Query.Tag := 1000;
Query.DatabaseName := Protocolo_Receita_q.DatabaseName;
Query.SQL.Add(' select trunc(dt_exame) dt_exame, ' +
' sum(vl_exame) vl_exame ' +
' from med_result_exame ' +
' where nr_seq_exame = ' + Med_Resultado_Exame_q.FieldByName('nr_seq_exame').AsString +
' and nr_seq_cliente = ' + nr_seq_cliente_ed.Text +
' and nvl(ie_valido,'+QuotedStr('S')+') <> ' + QuotedStr('N') +
' group by trunc(dt_exame) ' +
' order by 1 ');
TDBChart(Grafico).Series[i].Title := Med_Resultado_Exame_q.FieldByName('exame').AsString;
TDBChart(Grafico).Series[i].Marks.Style := smsValue;
TDBChart(Grafico).Series[i].Marks.Visible := True;
TDBChart(Grafico).Series[i].XLabelsSource := 'DT_EXAME';
TDBChart(Grafico).Series[i].YValues.ValueSource := 'VL_EXAME';
TDBChart(Grafico).Series[i].DataSource := Query;
TDBChart(Grafico).Series[i].Active := True;
TDBChart(Grafico).Series[i].ShowInLegend := True;
TDBChart(Grafico).Legend.TextStyle := ltsPlain;
TDBChart(Grafico).LeftAxis.Inverted := False;
In Java I insert the values:
for(WChartSerieValorVO valores : serie.getValores()){
DateTime dt1 = valores.getVlEixoX() != null ? new DateTime(((Timestamp)valores.getVlEixoX()).getTime()) : null;
Double db = valores.getVlEixoY() != null ? ((Number)valores.getVlEixoY()).doubleValue() : null;
s.add(dt1, db);
}
And TeeChart show :
The values in Delphi and Java are the same, but the design does not. I need the design in Java is the same in Delphi. How do I do?