Folding dimensions in code
Hi all.
I asked this already in the newsgroups, but I'm not sure which is the preferred place - newsgroups or this forum - and I didn't get a reply yet so I'm asking here too. Apologies if I'm grossly violating the rules ;-)
I'm creating a cube in code (Delphi) based on some user choices. I add fields like this:
slice.AddFieldTo('#Year_invoicedate', 'Year', rf_CapXAx);
slice.AddFieldTo('#Month_invoicedate', 'Month', rf_CapXAx);
Now I'd like to be able to have the months by default folded so that only the years are shown. I know I could only add the years and the result is almost the same, but I want the months there so that the first-time users will be more likely to notice them.
I did search the documentation but couldn't find any way to do this.
TIA!
I asked this already in the newsgroups, but I'm not sure which is the preferred place - newsgroups or this forum - and I didn't get a reply yet so I'm asking here too. Apologies if I'm grossly violating the rules ;-)
I'm creating a cube in code (Delphi) based on some user choices. I add fields like this:
slice.AddFieldTo('#Year_invoicedate', 'Year', rf_CapXAx);
slice.AddFieldTo('#Month_invoicedate', 'Month', rf_CapXAx);
Now I'd like to be able to have the months by default folded so that only the years are shown. I know I could only add the years and the result is almost the same, but I want the months there so that the first-time users will be more likely to notice them.
I did search the documentation but couldn't find any way to do this.
TIA!
Comments
Use in TfcSlice
property RegionFieldExpanded[ARegion: TfcRegionOfField; AFieldIndex: Integer]: Boolean;
to collapse dimention.
For example:
fcSlice.RegionFieldExpanded[rf_CapXAx, 0] := False;
or
fcSlice.XAxisFullExpanded[0] := False;
Oleg.
Thanks, that works for now; that method seems to only have one parameter but just [0] seems ok for my needs.
Thank you!