No announcement yet.

Hide columns in editable grid

  • Filter
  • Time
  • Show
Clear All
new posts

  • Hide columns in editable grid


    I have an editable grid which is a part of a master/detail form.
    The table of this editable grid is about 12 fields. But in the editable grid I only want to show 5 fields. This easy. No problem. I remove the fields in fields positioning.
    But when I do that this fields are also remove from the form when I try to edit or add a record.

    If I do not remove the fields in fields positioning and I use the macro sc_field_display to hide the field in the onLoad event, then again the field is gone in the editable grid and in the form.

    Is there a event that is fired when the edit form is shown. Or is there another way to achive this.

    Many thanks

  • #2
    Hello Andre,

    You could use sc_field_display to achieve that:

    Also, if you intend to never show those fields, you can remove those fields on the application settings.

    Bernhard Bernsmann


    • #3
      Thanks Bernard,
      I know how to remove fields from grids and forms.
      But I have now a editable grid and in the same application it generates a edit form. If I remove a field from the editable grid it is also removed from the edit form.


      • #4

        If you set the display off in sc_field_display in the onLoadRecord event, they will be hidden in the grid, but not in the update. I still haven't quite figured out how to get to an empty 'add' form. So if you do an 'add' from the grid, it just added a line at the bottom with the currently showing columns.

        And if you cancel the row at the bottom, it will refresh the grid with all columns (I have not tried turning the display off in the onRefresh event).