1

I am using Embarcadero® RAD Studio 10 Seattle Version 23.0.20618.2753

To make column read-only I used Grid_All_Party.Columns[2].ReadOnly := True;

and

to make cell read-only I used

 Grid_All_Party.ReadOnlys[1,0] := True;

but how to make all cells of grid read-only without using the below code personally for all columns.

Grid_Name.Columns[column_number].ReadOnly := True; 

2 Answers2

1

The Enabled property controls whether editing is enabled.

From the documentation:

Under Editing:

Enabled: Boolean: Enables or disables editing in the grid.

Tom Brunberg
  • 20,312
  • 8
  • 37
  • 54
1

There is an options property which has lots of option for TMSFMXGrid. here is what you want:

Grid_Name.Options.Editing.Enabled:=false;