Not sure how to word this, but I'm trying to pull some values from PO_PurchaseOrderHistoryInqDetail_bus. The script runs with no errors (button script), but no data is returned. I have a working script that pulls from SO_SalesOrderHistoryInquiryDetail_bus, so I'm sure it's something stupid that I'm just not seeing. Here are the two scripts:
The PO script that doesn't work:
Set oPOCpy = oSession.AsObject(oSession.GetObject("PO_PurchaseOrderHistoryInqDetail_bus"))
retVal = oPOCpy.SetKeyValue("PurchaseOrderNo$",srcOrdNum)
retVal = oPOCpy.SetKeyValue("SequenceNo$",sLineNum)
retVal = oPOCpy.Find()
retVal = oPOCpy.GetValue("ItemCode$",srcItemCode)
retVal = oPOCpy.GetValue("ItemType$",srcItemType)
retVal = oPOCpy.GetValue("ItemCodeDesc$",srcDescription)
retVal = oPOCpy.GetValue("ExtendedDescriptionKey$",srcExtDescKey)
The SO script that DOES work:
Set oSOCpy = oSession.AsObject(oSession.GetObject("SO_SalesOrderHistoryInquiryDetail_bus"))
retVal = oSOCpy.SetKeyValue("SalesOrderNo$",srcOrdNum)
retVal = oSOCpy.SetKeyValue("SequenceNo$",sLineNum)
retVal = oSOCpy.Find()
retVal = oSOCpy.GetValue("ItemCode$",srcItemCode)
retVal = oSOCpy.GetValue("ItemType$",srcItemType)
retVal = oSOCpy.GetValue("ItemCodeDesc$",srcDescription)
retVal = oSOCpy.GetValue("ExtendedDescriptionKey$",srcExtDescKey)
Any ideas on what I'm missing?