Passing parameters to Bm_inquiry_ui

SOLVED

client has requested to have a button link in the sales order entry screen that will pull up the bill of materials inquiry for the item selected.

I've done this before to launch item inquiry which requires a single parameter, but I'm having difficulties because bill of materials appears to want the revision number as well as the bill no.

The object reference doesn't seem to tell me exactly what parameters I need (or maybe I'm looking in the wrong place?) but I assume it is the item code and the revision.

The code below will without the revision parameter will launch BM Inquiry but then wants the revision number.

If I try to add the revision number I get an error suggesting wrong number of parameters or incorrect parameters.

Can anyone suggest the proper syntax to pass the item code and revision?

retVal = oSession.InvokeProgram(oSession.LookupTask("BM_BillInquiry_ui"),SO_SalesOrderDetail_bus_ItemCode,SO_SalesOrderDetail_bus_Revision)

I have also tried concatenating the item code and revision in various formats with no success.

Top Replies

Parents
  • 0

    Thank you jepritch.  That worked !  Never would have guessed that last part without your assist.

  • 0 in reply to TomTarget

    Glad I could help.  Any keys that are made up of more than one column. (ie Vendor = APDivisionNo + VendorNo, Bill = BillNo + Rev) when using as a key will be concatenated and each of the segments are padded with nulls (except the last segment).  For things like Vendor/Customer, the APDivisionNo/ARDivisionNo values are usually the full length so you do not have to pad those necessarily.

    These concatenated key values can be used in several functions such as .SetKey() or .Find()

    E

Reply
  • 0 in reply to TomTarget

    Glad I could help.  Any keys that are made up of more than one column. (ie Vendor = APDivisionNo + VendorNo, Bill = BillNo + Rev) when using as a key will be concatenated and each of the segments are padded with nulls (except the last segment).  For things like Vendor/Customer, the APDivisionNo/ARDivisionNo values are usually the full length so you do not have to pad those necessarily.

    These concatenated key values can be used in several functions such as .SetKey() or .Find()

    E

Children