1

What I want to achieve:- I want to add the fields such as year_mydatefield, month_mydatefield, quater_mydatefield on x-axis.

These break down fields are available during runtime in fields list, but I want to code them so that they appear automatically.

Is there any variable defined in fcCube.pas for this type of fields?

Or I can use other methods such as fcslice.AddCalcFieldTo? How to use them?

Research done:- From the example, I have learn how to put measures on X-axis using sMeasuresFieldName.

fcSlice1.AddFieldTo(sMeasuresFieldName, '', rf_CapXAx);

sMeasuresFieldName is defined in fcCube.pas. Unfortunately, Delphi XE2 cannot locate the fcCube.pas, and the programmer manual from fastCube only lists out all the methods and parameters but does not explain how to use them, limited example as well.

RRUZ
  • 134,889
  • 20
  • 356
  • 483
Colin Jong
  • 63
  • 1
  • 6
  • `fcCube` isn't installed with the FastReports version that ships with XE or XE2 Professional SKUs. Is it possible it's only available in the full version of FastReports or in a higher Delphi/RAD Studio SKU than the one you have? – Ken White Jan 20 '12 at 13:54

1 Answers1

0

Alternatively, you could add DateUtils to your unit and the use

myReportValue1 := YearOf(MyDateField);
myReportValue2 := MonthOf(MyDateField);
myReportValue3 := DayOf(MyDateField);
PCPGMR
  • 340
  • 2
  • 7