Foxtable(狐表)用户栏目专家坐堂 → 跨表引用


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

主题:跨表引用

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


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2014/8/26 14:13:00 [显示全部帖子]

改成这样

 

DataTables("学生成绩等级").Find("学期 = '" & e.DataRow("学期") & "' And 班级 = '" & e.DataRow("班级") & "'  ")("合格")


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


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2014/8/26 14:26:00 [显示全部帖子]

If e.Col.IsNumeric AndAlso e.Col.Name  <> "总分" Then
If e.Row.IsNull(e.Col.Name) = False
   
    Dim fdr As DataRow = DataTables("学生成绩等级").Find("学期 = '" & e.Row("学期") & "' And 班级 = '" & e.Row("班级") & "'  ")
    Dim hg As Integer = 60
    Dim yx As Integer = 80
    If fdr IsNot Nothing Then
        hg = fdr("合格")
        yx = fdr("优秀")
    End If
   
    If e.Row(e.Col.Name) <  hg Then
        DataTables("学生成绩").AddUserStyle("红牌", Color.Red, Color.DarkSlateGray)
        e.Style = "红牌"
       
    Else If e.Row(e.Col.Name) > yx Then
       
        DataTables("学生成绩").AddUserStyle("绿牌",Color.FromARGB(0, 192, 0), Color.DarkSlateGray)
        e.Style = "绿牌"
    End If
End If
End If

 

[此贴子已经被作者于2014-8-26 14:26:40编辑过]

 回到顶部