Simple BPM help Version 9.05.702

Sweet!  thanks!

I have it working with 

find first part where and
                                part.partnum = ipPartNum no-lock no-error.
if available part 
                  and part.character02 = "Small"
                                then do:

I'm surprised I was able to make it work, but I might still use yours.  Yours will show another version of a message and could be better than my message version.

Hey Guys,

I am trying to make a simple BPM to throw a message when Part.Character02 equals the word "Small" or "Medium".  UPS is implementing rules for Lithium Ion batteries being shipped.  I can't find a Condition that gives me the Part.Character02 field to use, so I assume I need custom code to get this done.  I don't know ABL, so I need some help.

Basically, UPS wants a certain label or document added to each shipment that meets a certain criteria which are labeled Small and Medium.  So I am going to add a UD field to the Part Entry Screen and fill that field with the word "Small" or "Medium" and throw a message on the screen for the shipper to add a label and/or document to the shipment package.  Can someone help me with the code to do that?

I don't know how much more difficult it will be, but UPS won't allow any shipments that meet these requirements to be sent Air (Alaska, Hawaii or International).  Is there some code we can add to stop the shipper from being able to ship an order that meets the Small or Medium category?

>> a certain label or document
>> BPM
Can you use a simple custom pack slip?
- add Part.Character02 to the RDD &  a custom report style?

If you need a pop-up, can you provide some more context?
- when/where do you want the message to display
---- e.g. checking part record as each line is added to a shipment entry
----  or checking part records when you print/preview the pack slip
No the Packing slip won't help.  UPS wants a designed label and document that we don't have control of the design.  It is a UPS form that can't be replicated.

I have a couple of other BPMs that spit out a message when a checkbox is True in the Part Table, but never done one with a word or words.  Those Post Processing BPMs are built using the CustShip.POValidatePart method.  They work great and the shippers can read the custom message and follow the instructions.  The check triggers when the item is scanned into the PackOut section of the Customer Shipment Entry.

I have created a custom PackOut process that only requires the shipper to Scan the Order#, Scan the Items and scan a Barcode that says "SHIP" that triggers the custom code to perform the F8, F5, F4 and check off the Shipped checkbox on the Summary tab.  Pretty slick custom code.  We ship around 5,000 order a day, so we need speed.

So the code really only needs to read the SKU that was scanned, see if the words "Small" or "Medium" are in the Part.Character02 field and spit out a message stating to add the label or doc.  Of course, I can handle that portion, but need the code to trigger the message.

Does that help explain a little more?

Does anyone have any thoughts and can help?
Are you adding trying to add this on the misc shipment entry program or the customer shipment entry program. 

here's a brief example you could probably use for misc shipment entry, maybe put it on the update method, pre-processing, with a condition checking for when you mark it shipped or something. If it's the customer shipment program you will need to replace with the mscchpdtl with the customer shipment detail info. 

For each ttMscShpDt no-lock where = Cur-Comp, first part no-lock where = cur-comp and part.partnum = ttMscShpDt.Partnum.
if part.shortchar02 = 'Small' then
{lib/PublishInfoMsg.i &InfoMsg = "'Add SMALL Label to box'"  &InfoSeverity = {&MESSAGE_INFO}} 
else if part.shortchar02 = 'Large' then
{lib/PublishInfoMsg.i &InfoMsg = "'Add LARGE Label to box'"  &InfoSeverity = {&MESSAGE_INFO}} 

hope this helps. 


I am doing this in the customer shipment entry and using the CustShip.POValidatePart method.  Can you tailor your code to check the Part.Character02 field to see if "Small" or "Medium" is in the field and if true I can spit out the message to add the labels?
>>shipment entry and using the CustShip.POValidatePart
 I think you can just substitute:
-  ttPackOut for ttMscShpDt
- Part.Character02 for part.shortchar02
But I haven't actually tested this

/* Hazard Material Labels */
For each ttPackOut no-lock where = Cur-Comp, first part no-lock where = cur-comp and part.partnum = ttPackOut.Partnum.
    if part.Character02 = 'Small' then
        {lib/PublishInfoMsg.i &InfoMsg = "'Add UPS Smaill Label to box'"  &InfoSeverity = {&MESSAGE_INFO}}
    else if part.Character02 = 'Medium' then
        {lib/PublishInfoMsg.i &InfoMsg = "'Add UPS Medium Label to box'"  &InfoSeverity = {&MESSAGE_INFO}}