红色的代码是ft可以用的。那么怎么转换成vs可以用的?就是vs中怎么实现红色代码的逻辑?
If Bind = 1 Then
Dim dr As DataRow = DataTables("可用数量表").SQLFind("物料编码 = '" & wlbm & "'")
If dr IsNot Nothing Then
strSql = "s elect * from [可用数量表] where " & "and id_flag = '" & dr("id_flag") & "'"
End If
ElseIf Bind = "" Or Bind = "null" Then
filter &= "and 在库数量 > 0"
strSql = "s elect * from [可用数量表] where " & filter
End If
Dim adapter As New SqlClient.SqlDataAdapter(strSql, cn)
Dim dt As New DataTable
adapter.Fill(dt)
cn.Close()
Dim state As String = OrderQueryBLL.ConvertToJsonObject(dt)
Return state