试试:
adodc1.recordsource="select * from 條碼代號 where dell機種='" + trim(text5.text) + "'"

解决方案 »

  1.   

    如果dell机种字段是字符型的,那改为
    adodc1.recordsource="select * from 条码代号 where dell机种='" & trim(text5.text) & "'"
    如果dell机种字段是数值型的,那改为
    adodc1.recordsource="select * from 条码代号 where dell机种=" & val(trim(text5.text))
      

  2.   

    dell機種是字符型的,
    我的查詢句子是沒錯的,
    但是就不能refresh, 這是為什麼??
      

  3.   

    您給我的句子也是沒錯,但同樣不能refresh
      

  4.   

    adodc2.recordset.update是可以的
    可是就是不能refresh,請問高手問題出在哪!還想問問 vb中是如何在txt中寫入,主要有哪幾個函數可用能列舉幾個嗎??