PDA

View Full Version : Macro For Printing Labels



YBQM
09-04-2018, 10:19 AM
Hi,

I would like assistance with VBA code for the attached spreadsheet. The spreadsheet has 3 tabs: Tables, MoveTags, Label. Tables Tab generates data automatically by using SQL and the data from A1 on the MoveTags Tab.
MoveTags has the button that needs to ask for input. The button and UserForm are created.
The label tab is the one that needs to be printed.


On the attached spreadsheet, the total amount of labels that need to be printed is 14. This is because there are a total of 3 SubNo (0,1,2) and each SubNo has a RSC (SubNo 0 has 6, SubNo 1 has 4, SubNo 2 has 4)
All of this will change once a different Base ID is entered.


So once you click on the button and enter the Work Order, in this case W157772, and then hit print the following needs to happen:
The Label Tab needs to be filled out with the information from the Tables Tab. Like the attached pictures. This needs to be done 14 times and printed on the zebra label printer that on the local network.


Label 1-6 will have Part No. 29502066-14
Label 7-10 will have Part No. 29502066-14A
Label 11-4 will have Part No. 29502066-4B

Your help on this is greatly appreciated.
Thanks

YBQM
09-04-2018, 01:16 PM
Where it says part Number 29502066-14A, the Leg No.: should be 1 and not 0. Everything else looks good.