FAST CUBE DISPLAY FORMAT

edited 2:37PM in FastCube
I want to change the format of a field in Cube. I want to give me currency format PRICE = 1.100, rather than price = 1.100,00

Comments

  • edited 2:37PM
    Hi.

    Examples:

    To change format in measure:
    procedure ex_ChangeDisplayFormatOfMeasureAmount;
    var AIndex: integer;
    begin
    AIndex := fcSlice.FieldsOfRegion(rf_CapFacts).IndexOf('Measure_1');
    if AIndex >= 0 then
    begin
    fcSlice.BeginUpdate;
    fcSlice.CapFactsFieldsAbs[AIndex].VisibleInData := True;
    fcSlice.CapFactsFieldsAbs[AIndex].DisplayFormat.Kind := fkNumeric;

    fcSlice.CapFactsFieldsAbs[AIndex].DisplayFormat.FormatStr := '%2.2n';

    fcSlice.EndUpdate;
    end
    end;

    To change format in measure:
    procedure ex_ChangeDateFormatInDimentions;
    var AIndex : integer;
    begin
    AIndex := 0;
    if fcSlice.SliceFields.Find('Date', AIndex) then
    begin
    fcSlice.BeginUpdate;
    fcSlice.SliceFields[AIndex].CubeField.DisplayFormat.FormatStr := 'mmm/dd'
    fcSlice.EndUpdate;
    end;
    end;

    Also You can change default formats in TfcCube.

    Also see See compiled demo "FastCube examples".

    Oleg.

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.