老师,我要点击“跟进情况”这个单元格,然后进入到对应的子网页里,这个子页面是对应的明细表。
请问这个代码要怎么编写?
Case "list.htm"
Dim wb As New WeUI
For i As Integer = 0 To Tables("客户信息表").Rows.Count - 1
Dim r As Row = Tables("客户信息表").Rows(i)
With wb.AddTable("","Table" & i)
.Highlight = -1 '关闭高亮显示功能
.ColWidth = "30px,70px,65px,65px,65px" '设置列宽
.Attribute = "Style=""text-align:center"""
.head.AddRow("序号","客户名称","经纪人","负责人","房源")
With .body.AddRow
.AddCell(i+1,"rowspan=5")
.AddCell(r("客户名称"))
.Addcell(r("经纪人"))
.Addcell(r("负责人"))
.Addcell(r("房源"),"class='zts'")
End With
With .body.AddRow()
.AddCell(r("需求"),"colspan='5'")
End With
With .body.AddRow()
.AddCell(r("跟进情况"),"colspan='5'class='bjs1'")
End With
With .body.AddRow()
.AddCell(r("状态"),"colspan='5'class='bjs2'")
End With
End With
Vars("khbh") = r("客户编号")
Next
e.WriteString(wb.Build)
Case "gjqk.htm"
Dim wb As New WeUI
Dim r As DataRow = DataTables("客户信息表").Find("[客户编号] = '" & "001" & "'")
With wb.AddTable("","Table1")
.Highlight = -1 '关闭高亮显示功能
.ColWidth = "70px,65px,65px,65px" '设置列宽
.Attribute = "Style=""text-align:center"""
.head.AddRow("客户名称","经纪人","负责人","房源")
With .body.AddRow
.AddCell(r("客户名称"))
.Addcell(r("经纪人"))
.Addcell(r("负责人"))
.Addcell(r("房源"),"class='zts'")
End With
With .body.AddRow()
.AddCell(r("需求"),"colspan='5'")
End With
With .body.AddRow()
.AddCell(r("状态"),"colspan='5'class='bjs2'")
End With
With wb.AddTable("","Table2")
.Highlight = -1 '关闭高亮显示功能
.ColWidth = "65px,50px" '设置列宽
.Attribute = "Style=""text-align:center"""
.CreateFromDataTable(DataTables("跟进情况表"),False,"客户编号='001'","跟进日期 desc","跟进日期","跟进人","跟进情况")
End With
End With
e.WriteString(wb.Build)

此主题相关图片如下:微信图片_20190616004901.png
