Foxtable(狐表)用户栏目专家坐堂 → 帮我看看哪里错了?


  共有3910人关注过本帖树形打印复制链接

主题:帮我看看哪里错了?

帅哥哟,离线,有人找我吗?
hongye
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:一尾狐 帖子:437 积分:2949 威望:0 精华:0 注册:2011/3/15 12:49:00
帮我看看哪里错了?  发帖心情 Post By:2020/3/11 0:56:00 [显示全部帖子]

Dim cls() As String = {"样衣款号","类别","项目名称","规格","成份或质地","克重","门幅","单位","单耗","单价","金额","供应商"} '定义列名
Dim lxs() As String = {"String","String","String","String","String","Short","String","String","Double","Double","Double","String"} '定义Type类型
Dim cds() As String = {"55","55","55","55","55","","16","16","","","","50"}
Dim dtb As New DataTableBuilder("临时核价表")
For i As Integer = 0 To  cls.Length - 1
    dtb.AddDef(cls(i),Gettype(lxs(i)),cds(i))
Next

图片点击可在新窗口打开查看此主题相关图片如下:01.jpg
图片点击可在新窗口打开查看

请问这个该怎么写?


 回到顶部
帅哥哟,离线,有人找我吗?
hongye
  2楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:一尾狐 帖子:437 积分:2949 威望:0 精华:0 注册:2011/3/15 12:49:00
  发帖心情 Post By:2020/3/11 11:52:00 [显示全部帖子]

Dim ks As WinForm.Label = e.Form.Controls("款号")
Dim yk As WinForm.Label = e.Form.Controls("样衣款号")
Dim lb As WinForm.Label = e.Form.Controls("类别")
Dim jh As WinForm.Label = e.Form.Controls("计划交期")
Dim bj As WinForm.TextBox = e.Form.Controls("报价金额")
Dim zz As WinForm.TextBox = e.Form.Controls("最终价格")
Dim gps() As  String  = {"面料","辅料","二次加工"} '定义分组名称
Dim te() As String = {"客户","客户担当","类别","品名","款号","样衣款号","报价数量","计划交期","原料费用","辅料费用","二次加工费用","工缴费用","其他费用","管理费用","核价金额","技术担当"}
Dim cls() As String = {"款号","样衣款号","项目名称","规格","成份或质地","克重","门幅","单位","单耗","单价","金额","供应商","分类"} '定义列名
Dim lxs() As Object = {"String","String","String","String","String","Short","String","String","Double","Double","Double","String","String"} '定义Type类型
Dim cds() As String = {"55","55","55","55","55","","16","16","","","","50","40"}
Dim wdh() As String = {140,140,140,135,90,45,45,45,58,65,67,88,85}
Dim dtb As New DataTableBuilder("临时核价表")
For i As Integer = 0 To cls.Length - 1
    If lxs(i) = "String" Then
        dtb.AddDef(cls(i),Gettype(String),cds(i))
    ElseIf lxs(i) = "Double" Then
        dtb.AddDef(cls(i),Gettype(Double),cds(i))
    ElseIf lxs(i) = "Short" Then
        dtb.AddDef(cls(i),Gettype(Short),cds(i))
    End If
Next
dtb.Build()
For i As Integer = 0 To cls.Length - 1
    Tables("临时核价表").Cols(cls(i)).Width  = wdh(i)
Next
For i As Integer = 0 To gps.Length - 1
    Dim dt As DataTable = DataTables(gps(i) &"核价")
    msgbox(dt.name)
    Dim drs = dt.Select("款号 = '" & ks.Text & "'and 样衣号 like '%" & yk.Text & "%'","_sortkey")
    msgbox(drs.count)
    For Each dr As DataRow In drs
        Dim r As  DataRow = DataTables("临时核价表").AddNew()
        r("款号") = ks.Text
        r("样衣款号") = yk.Text
        r("项目名称") = dr(gps(i) & "名称")
        r("分类") = dt.name
    Next
Next
MainTable = Tables("临时核价表")

这个为什么没有被筛选出来呢?哪里错了?

 回到顶部
帅哥哟,离线,有人找我吗?
hongye
  3楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:一尾狐 帖子:437 积分:2949 威望:0 精华:0 注册:2011/3/15 12:49:00
  发帖心情 Post By:2020/3/11 12:19:00 [显示全部帖子]

刚刚漏了窗口名,因为表是窗口里的,但是又出来新问题了

图片点击可在新窗口打开查看此主题相关图片如下:01.jpg
图片点击可在新窗口打开查看
这啥意思?


 回到顶部