dfolzenlogen
New Member
- Joined
- Oct 18, 2009
- Messages
- 36
I have 2 users both accessing the same Excel file. One user is able view barcodes which look like
:
The second user sees the following:
It's the same file. The barcodes are generated via Excel vba. What they see is how the file prints. The user whose barcode splits is able to capture the barcode on one page if she prints manually using Microsoft Print to PDF but that is not feasible as part of our archiving and file naming process which is automated.
The routine for printing and naming the file is as follows:
Any suggestions? Thanks.
:
The second user sees the following:
It's the same file. The barcodes are generated via Excel vba. What they see is how the file prints. The user whose barcode splits is able to capture the barcode on one page if she prints manually using Microsoft Print to PDF but that is not feasible as part of our archiving and file naming process which is automated.
The routine for printing and naming the file is as follows:
VBA Code:
'Save the selected tabs out into individual PDFs
For Each ws In ThisWorkbook.Worksheets
If ws.visible = xlSheetVisible Then
If Trim(UCase(ws.Name)) = "TRANSFER" Then
Application.StatusBar = "Saving Transfer worksheet..."
ws.ExportAsFixedFormat Type:=xlTypePDF, Filename:=strFullPath & strSubFolder & " – (2) Transfer.pdf", _
Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False
ElseIf Trim(UCase(ws.Name)) = "EXHIBIT A" Then
If Trim(ws.Range("rngExhibitHeader").Offset(1, 0)) <> "" Then
Application.StatusBar = "Saving Exhibit A worksheet..."
ws.ExportAsFixedFormat Type:=xlTypePDF, Filename:=strFullPath & strSubFolder & " – (3) Exhibit A.pdf", _
Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False
End If
ElseIf Trim(UCase(ws.Name)) = "EXHIBIT A (2)" Then
If Trim(ws.Range("rngExhibit2Header").Offset(1, 0)) <> "" Then
Application.StatusBar = "Saving Exhibit A (2) worksheet..."
ws.ExportAsFixedFormat Type:=xlTypePDF, Filename:=strFullPath & strSubFolder & " – (3) Exhibit A.pdf", _
Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False
End If
ElseIf Trim(UCase(ws.Name)) = "BARCODES" Then
Application.StatusBar = "Saving Barcode worksheet..."
ws.ExportAsFixedFormat Type:=xlTypePDF, Filename:=strFullPath & strSubFolder & " – (1) Barcode.pdf", _
Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False
ElseIf Trim(UCase(ws.Name)) = "DO" Then
Application.StatusBar = "Saving DO worksheet..."
ws.Range("BA1:BZ62,DA1:DZ62").ExportAsFixedFormat Type:=xlTypePDF, Filename:=strFullPath & strSubFolder & _
" – (4) DO (" & strToOwner & ").pdf", Quality:=xlQualityStandard, IncludeDocProperties:=True, _
IgnorePrintAreas:=False
End If
End If
Next ws
'Save out each additional DO worksheet (as needed)
For Each ws In ThisWorkbook.Worksheets
If ws.visible = xlSheetVisible Then
If Trim(UCase(ws.Name)) Like "DO*" And Trim(UCase(ws.Name)) <> "DO" Then
Application.StatusBar = "Saving " & ws.Name & " worksheet..."
ws.Range("BA1:BZ62").ExportAsFixedFormat Type:=xlTypePDF, Filename:=strFullPath & strSubFolder & " – (" & x & ") " _
& Trim(UCase(ws.Name)) & ".pdf", Quality:=xlQualityStandard, IncludeDocProperties:=True, _
IgnorePrintAreas:=False
x = x + 1
End If
End If
Next ws
Any suggestions? Thanks.