Hi all,
I use an rtf file to print stock details and like to add the barcode which is in a picturebox. all of the data merges nicely, but i cannot seem to get the picture on the page. i managed to put the picture on the clipboard. when i open the printpage now it is literally under my richtmousebutton. but how do i get it in my report. below is the part of the printform where the data is merged.
thanks a lot!
john
Public Sub show_stockprint()
On Error GoTo check_err1
rpt1.FileName = App.Path & "/stockprint.rtf"
temp = rpt1.TextRTF
temp = Replace(temp, ":roduct no::", FRMSTOCKITEMS.TXTF(2).Text)
temp = Replace(temp, ":roduct.description::", FRMSTOCKITEMS.TXTF(2).Text)
temp = Replace(temp, ":utch::", FRMSTOCKITEMS.TXTF(11).Text)
temp = Replace(temp, ":apiamentu::", FRMSTOCKITEMS.TXTF(12).Text)
temp = Replace(temp, "::Category::", FRMSTOCKITEMS.TXTF(16).Text)
temp = Replace(temp, "::Units::", FRMSTOCKITEMS.TXTF(6).Text)
temp = Replace(temp, ":rice::", FRMSTOCKITEMS.TXTF(9).Text)
rpt1.TextRTF = temp
rpt1.hwnd , WM_PASTE, 0, 0
Exit Sub
check_err1:
If Err.Number = 75 Then
MsgBox "File: " & App.Path & "/stockprint.rtf" & " is Open, Please Close It", vbCritical
MsgBox "File: " & App.Path & "/stockprint.rtf" & " is Open, Please Close It", vbCritical
End
Else
MsgBox "Some Error Occured: " & Err.Number & " " & Err.Description & vbCrLf & vbCrLf & "Program May Not Work Properly", vbCritical
MsgBox "Some Error Occured: " & Err.Number & " " & Err.Description & vbCrLf & vbCrLf & "Program May Not Work Properly", vbCritical
End
End If
End Sub
I use an rtf file to print stock details and like to add the barcode which is in a picturebox. all of the data merges nicely, but i cannot seem to get the picture on the page. i managed to put the picture on the clipboard. when i open the printpage now it is literally under my richtmousebutton. but how do i get it in my report. below is the part of the printform where the data is merged.
thanks a lot!
john
Public Sub show_stockprint()
On Error GoTo check_err1
rpt1.FileName = App.Path & "/stockprint.rtf"
temp = rpt1.TextRTF
temp = Replace(temp, ":roduct no::", FRMSTOCKITEMS.TXTF(2).Text)
temp = Replace(temp, ":roduct.description::", FRMSTOCKITEMS.TXTF(2).Text)
temp = Replace(temp, ":utch::", FRMSTOCKITEMS.TXTF(11).Text)
temp = Replace(temp, ":apiamentu::", FRMSTOCKITEMS.TXTF(12).Text)
temp = Replace(temp, "::Category::", FRMSTOCKITEMS.TXTF(16).Text)
temp = Replace(temp, "::Units::", FRMSTOCKITEMS.TXTF(6).Text)
temp = Replace(temp, ":rice::", FRMSTOCKITEMS.TXTF(9).Text)
rpt1.TextRTF = temp
rpt1.hwnd , WM_PASTE, 0, 0
Exit Sub
check_err1:
If Err.Number = 75 Then
MsgBox "File: " & App.Path & "/stockprint.rtf" & " is Open, Please Close It", vbCritical
MsgBox "File: " & App.Path & "/stockprint.rtf" & " is Open, Please Close It", vbCritical
End
Else
MsgBox "Some Error Occured: " & Err.Number & " " & Err.Description & vbCrLf & vbCrLf & "Program May Not Work Properly", vbCritical
MsgBox "Some Error Occured: " & Err.Number & " " & Err.Description & vbCrLf & vbCrLf & "Program May Not Work Properly", vbCritical
End
End If
End Sub