RT,请教各位大虾。
------解决方案--------------------------------------------------------
------解决方案--------------------------------------------------------
thisform.grid1.ReadOnly=IIF(this.ActiveRow=RECNO(),.f.,.t.)
只能修改当前行
试试
------解决方案--------------------------------------------------------
上述代码放在AfterRowColChange事件中
------解决方案--------------------------------------------------------
thisform.grid1.ReadOnly=IIF(this.ActiveRow=RECNO(),.f.,.t.)
thisform.grid1.ReadOnly=IIF(你的条件,.f.,.t.)
------解决方案--------------------------------------------------------
代码放到列的 Text1 的 when 事件中:
if 符合编辑条件
return .t.
else
return .f.
endif
或者: return 是否符合编辑条件
------解决方案--------------------------------------------------------