综上所述,我们三个都没有用你字符转来转去的的思路。
有人说VFP不行了,我想说,你连VFP十分之一的功能都不会用,你怎么知道VFP不行?本人拒绝回答学生的问题我回答问题一般情况下只提供思路不提供代码,请理解
CLOSE DATABASES USE 大小比较1 FOR i = 0 TO 2 a1 = "M" + STR(i, 1) + "大" a2 = "M" + STR(i, 1) + "小" a3 = "M" + STR(i, 1) + "同" a4 = "M" + STR(i, 1) BLANK FIELDS (a1), (a2), (a3) ALL ok = .F. SCAN IF ok = .F. IF ISDIGIT(&a4) = .T. cStr = ALLTRIM(&a4) ok = .T. ENDIF ELSE IF ISDIGIT(&a4) = .T. DO CASE CASE PADR(ALLTRIM(&a4), 10, " ") > PADR(cStr, 10, " ") REPLACE (a1) WITH a1 CASE PADR(ALLTRIM(&a4), 10, " ") < PADR(cStr, 10, " ") REPLACE (a2) WITH a2 CASE PADR(ALLTRIM(&a4), 10, " ") == PADR(cStr, 10, " ") REPLACE (a3) WITH a3 ENDCASE cStr = ALLTRIM(&a4) ENDIF ENDIF ENDSCAN ENDFOR BROWSE
[此贴子已经被作者于2020-1-2 11:32编辑过]