برجاء المساعدة فى وجود رسالة خطأ تظهر اثناء الطباعة
كود الطباعة
محتاج ارفع صورة الخطأ لا تظهر
كود الطباعة
كود :
Public Sub MyPrint()
On Error Resume Next
REM ///////////////////////////// //////////////////////////////////
CRV1.ReportSource = New CryBill
Dim AdView As New SqlDataAdapter("SELECT * FROM View_Bill where Bil2_Shift=" & Val(txtShift.Text) & " And Bil2_No=" & Val(txtNo.Text) & "", Conn)
'--------------------------------------------------------------------
Conn.Open()
DsView.Clear()
AdView.Fill(DsView, "View_Bill")
Conn.Close()
'===================================================================
Dim rpt As New CryBill
rpt.SetDataSource(DsView)
Me.CRV1.ReportSource = rpt
Me.CRV1.RefreshReport()
rpt.PrintToPrinter(1, False, 0, 0)
rpt.Close()
rpt.Dispose()
rpt.Refresh()