Public Sub loadlabe1()
Dim sql_Sel As String
Dim hIssId As Integer = 0
hIssId = Request.QueryString("patID")
Try
Dim rptDoc As New ReportDocument()
Dim DM As New DataManager
Dim Tbl As DataTable
Dim doc As New ReportDocument()
sql_Sel = "exec RptOPIPCaseSheet @Opt=2,@patID=" & hIssId & ""
Tbl = DataManager.ExecuteScalarDS(sql_Sel, Me.SqlCon, "RptIPCaseSheet")
doc.Load(Server.MapPath("Reports\rIPLabLbl_A00001.rpt"))
doc.SetDataSource(Tbl)
CrystLabl.ReportSource = doc
'doc.PrintOptions.PaperSize = PaperSize.PaperA4
'doc.PrintToPrinter(1, False, 1, 1)
'crypt.PrintMode = PrintMode.ActiveX
'FileName = Me.hRptType.Value + "labe1Print" + Request.QueryString("patID")
'doc.ExportToDisk(ExportFormatType.PortableDocFormat, Server.MapPath("../Print/" + FileName + ".pdf"))
Catch ex As Exception
labelmsg.Text = ex.ToString()
End Try
End Sub