thisform.grid1.SetAll('ReadOnly',IIF(CanEdit=1, .F., .T.),'Column')
thisform.grid1.SetAll('Enabled',IIF(CanEdit=1, .F., .T.),'Column')