根据错误提示,楼主的底盘号是字符型,应该:
For Each dr As DataRow In DataTables("A").DataRows If DataTables("B").Compute("Count(底盘号)","底盘号 = '"& dr("底盘号") & "'") > 0 Then dr("客户等级") = "CC" End IfNext
楼主总是犯这中错误,合成表达式是最重要的基本功,请细看:
http://www.foxtable.com/help/topics/1284.htm