How to hide columns in cell detail form ?

edited 4:43AM in FastCube 2
Hi,

How to hide columns in cell detail form ?
I would like to hide columns directly on the double click event.

I find no examples.

thanks

Comments

  • edited 4:43AM
    rxseac wrote: »
    Hi,

    How to hide columns in cell detail form ?
    I would like to hide columns directly on the double click event.

    I find no examples.

    thanks

    Support response :

    Add fcxDetailGrid in uses.

    Hi.

    Standard code:

    procedure TfcxSliceDataZone.DblClick(X, Y: Integer);
    var
    DataPoint: TfcxDataPoint;
    begin
    DataPoint := PointToDataPoint(Point(X, Y));
    if Assigned(Grid.OnDataDblClick) then
    Grid.OnDataDblClick(Self, DataPoint.x, DataPoint.y)
    else
    begin
    if not Assigned(FDetailColumns) then
    FDetailColumns := TfcxCubeDataColumns.Create;
    ShowDetails(Grid.Slice, Grid.PaintStyle, Point(DataPoint.X, DataPoint.Y), FDetailColumns, Grid);
    end;
    inherited;
    end;


    Example of OnDataDblClick event:
    SliceGrid1DataDblClick(Sender: TfcxSliceDataZone; XAxisIndex, YAxisIndex : Integer)
    var
    DetailColumns: TfcxCubeDataColumns;
    NeedHideItemIndex: integer;
    begin
    DetailColumns := TfcxCubeDataColumns.Create;
    DetailColumns.Update(Sender.Grid.Slice.Cube);
    NeedHideItemIndex := 0; //!!!! Set index of field to hide
    DetailColumns.AbsItems[NeedHideItemIndex].Visible := False;
    ShowDetails(Sender.Grid.Slice, Sender.Grid.PaintStyle, Point(XAxisIndex, YAxisIndex), DetailColumns, Sender.Grid);
    end;

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.