用if...then 
复杂一点,但是可能管用
只是建议

解决方案 »

  1.   

    if...then的确可以实现,但在判断条件较多的情况下,复杂得一塌糊涂,还请指点迷津
      

  2.   

    其实case 就是好多的if...then
    你少用点else 就是了
    无非是  if 条件1 then 过程1; 
            if 条件2 then 过程2;
            ....
      

  3.   

    procedure case(sendstr:string);
    var sample:array[1..4] of string;
        i:integer;
    begin
       i:=1;
       sample[1]:='abcd';
       sample[2]:='efd';
       sample[3]:='mnq';
       sample[4]:='xyz'; 
       while (i<=4) and (sample[i]<>sendstr) do
         i:=i+1;
       case i of
         1:
         2:
         3:
         4:
       else
       end; 
    end;