brecord['returntime']        ??????????????

解决方案 »

  1.   

    brecord是表,returntime是此表中的一个字段(日期类型的)
      

  2.   

    fdm.brecord['returntime']<datetostr(now)
    出错了,改成
    fdm.brecord['returntime']<now
      

  3.   

    如果returntime字段在数据库里面是DateTime型,那么fdm.brecord['returntime']则在Delphi里面是ftDateTime型,而你却吧 now转换成String,两边类型不匹配,当然要出错。应该改成
    if fdm.brecord.FieldByName('returntime').AsString<datetostr(now) then