You can use the above code to Toggle ReadOnly status during runtime. This code is tested.
From the next version, we have provided DATA lReadOnly. We can toggle this at runtime with oEdit:lReadOnly := .T. or .F..
#define EM_SETREADONLY 0x00CF
//
//
If( oEdit:WinStyle( ES_READONLY ), oEdit:SendMsg( EM_SETREADONLY, 0 ), ;
oEdit:SendMsg( EM_SETREADONLY, 1 ) ) }