Filter Item List in Sub Form - Based on Parent Form

leikelmanleikelman Member Posts: 31
I am not sure what I need to happen can actually be done, but here is the situation.

In the Item Table (Table 27), we have a field called "Customer No.". The default sales order form (Form 42 - Sales Order) uses a subform to enter the item detail information (Form 46 - Sales Order Subform). What I would like to happen is when someone is in the subform and looks up the items, by going into the No. column and either hitting the lookup arrow or pressing F5, I would like that list (Form 31 - Item List) filtered based on "Sell-to Customer No." from the Sales Header = "Customer No." from the Item table.

Please let me know if you need clarification on anything.

Thank you,

Leo

Comments

  • SavatageSavatage Member Posts: 7,142
    So to be clear-

    You added a field to the item table called customer no.
    Here you can assign a customer no to a particular item.

    when your in an order and you want to lookup an item, the list that appears should be filtered by the customer no on the sales header.

    Is this correct? So an item can NEVER belong to 2 or more customers?

    If you look at the code on Cross-Reference No on the sales line - you see it does just what you need.

    Each item can have multiple cross-reference numbers based on each customer. when you lookup on the sales line in the cross-reference field it filters the numbers just for that customer. Check out the code there.
Sign In or Register to comment.