'''
Dim doc As New PrintDoc() '定义一个报表
doc.PageSetting.PaperKind = 11 '纸张类型改为A5
Doc.PageSetting.LeftMargin = 1 '设置左边距
Doc.PageSetting.RightMargin = 1 '设置右边距
Doc.PageSetting.TopMargin = 1 '设置上边距
Doc.PageSetting.BottomMargin = 1 '设置下边距
Doc.Columns.Add() '增加第一栏
Doc.Columns.Add() '增加第二栏
Doc.Columns(0).Width = 101 '第一栏的宽度为101毫米
Doc.Columns(0).Spacing = 10 '栏间距1毫米
Dim k As Integer= val(e.form.controls("textbox7").text)
For i As Integer = 1 To k
Dim rt As New prt.RenderTable() '定义一个表格对象
Dim rx As prt.RenderText '定义一个文本对象
Dim CurRow As Row = Tables("printA5").Current
'设置水印
rx = New prt.RenderText '设置文本对象的内容
rx.Text = CurRow("背番号") '设置文本内容
rx.Width = 80 '宽度
rx.Height = 50 '高度
rx.x = 20
rx.y = 23
'rx.Style.TextAngle = 45 '旋转45度
rx.Style.TextAlignHorz = prt.AlignHorzEnum.Center '水平居中对齐
rx.Style.TextAlignVert = prt.AlignVertEnum.Center '垂直居中对齐
rx.Style.FontSize = 110 '字体大小为110磅
rx.Style.FontBold = True '字体加粗
rx.Style.TextColor = Color.LightGray '文本颜色为灰色
Doc.WaterMark = rx '作为水印使用