回复 4楼 sdta
thisform. grid1.name = "grdcur"
cj = ALLTRIM(thisform.Text1.value)
gys = ALLTRIM(thisform.Text2.value)
spm =ALLTRIM(thisform.Text3.value)
mcc =ALLTRIM(thisform.Text4.value)
cmd = "BROWSE FOR .t."
IF !EMPTY(cj)
cmd = cmd + "and UPPER(cj) $ UPPER(厂家 )"
ENDIF
IF !EMPTY(gys)
cmd = cmd + "and UPPER(gys) $ UPPER(供应商)"
ENDIF
IF !EMPTY(spm)
cmd = cmd + "and UPPER(spm) $ UPPER(商品名)"
ENDIF
IF !EMPTY(mcc)
cmd = cmd + "and UPPER(mcc) $ UPPER(名称 ) name GrdCur "
ENDIF
&cmd
thisform.grdcur.column1.width = 30
thisform.grdcur.column2.width = 100
thisform.grdcur.column3.width = 100
thisform.grdcur.column1.BackColor = RGB(220,220,220)
thisform.grdcur.GridLineColor= RGB(128,128,128)
thisform.grdcur.column1.sparse = .F.
thisform.grdcur.column1.Alignment = 2