你可以在selectcell里处理 如果你想使第2列只读,你可以在重载selectcell事件 加入一下代码 if arow=1 then stringgrid1.Options:=[goFixedVertLine,goFixedHorzLine,goVertLine,goHorzLine,goRangeSelect] else stringgrid1.Options:=[goFixedVertLine,goFixedHorzLine,goVertLine,goHorzLine,goRangeSelect,goediting]
如果你想使第2列只读,你可以在重载selectcell事件
加入一下代码
if arow=1 then
stringgrid1.Options:=[goFixedVertLine,goFixedHorzLine,goVertLine,goHorzLine,goRangeSelect]
else stringgrid1.Options:=[goFixedVertLine,goFixedHorzLine,goVertLine,goHorzLine,goRangeSelect,goediting]