Hide columns in editable grid

Hi

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
Andre

Hello Andre,

You could use sc_field_display to achieve that: downloads.scriptcase.com.br/downloads/v7/manual/en_us/webhelp/manual_mp/28-Macros/00-macros_sc.htm#sc_field_display

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

regards,
Bernhard Bernsmann

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.
Brdgs
Andre

Andre,

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).