También le cambio si es editable o no y el texto que muestra, esto último logro hacerlo, pero no el cambio de color
- Code: Select all Expand view
aData := {{1,"Articulo 1",10,12},{2,"Articulo 2",15,0},{3,"Articulo 3",0,15},{4,"Articulo 4",15,15}}
@ 40,10 XBROWSE oBrw SIZE -10,-10 PIXEL OF oDlg ;
ARRAY aData ;
AUTOCOLS FASTEDIT;
SIZES 60,305,90,90,90,90,90,90,90,90;
CELL LINES NOBORDER
PintaBrw(oBrw,0)
for each oCol in oBrw:aCols
NoMostrar(oCol)
NEXT i
WITH OBJECT oBrw
:nFreeze := 2
:CreateFromCode()
END
....
STATIC FUNCTION NoMostrar(oCol)
IF valtype(oCol:value) = "N"
oCol:bStrData := { | | IF(oCol:value > 0 ,oCol:value,"NO EXISTE")}
oCol:bEditWhen := { | | oCol:value > 0 }
IF oCol:value > 0
oCol:nEditType := 1
ELSE
oCol:bClrStd := {|| {CLR_WHITE,CLR_RED } }
ENDIF
ENDIF
RETURN nil