Skip to main content
Answer

What formula can I use?

  • January 24, 2023
  • 4 replies
  • 137 views

Forum|alt.badge.img+1

Hello,

Been here multiple times with this same report, I’d like to ask how it’s possible for me to NOT display the qty and uom of an item that lists down multiple serial numbers every time SN is displayed?

I originally used this Prev statement:

IIf(Prev([SOShipLine.OriginalShippedQty])=[SOShipLine.OriginalShippedQty], '', [SOShipLine.OriginalShippedQty]

And offourse, the result is, I’ll never get the same QTY or same UOM, though it’s another Item in the list. I do not wish that to happen, what formula can I use? I appreciate any help!

 

Paula

Best answer by aaghaei

try
 

=IIf(IsNull([SOShipLineSplit.LotSerialNbr], '')<>'', IIf(Prev([SOShipLine.TranDesc])=[SOShipLine.TranDesc], '',[SOShipLine.UOM]), [SOShipLine.UOM])

 

or compare previous and current SOShipLine.InventoryID instead of TranDesc

4 replies

Forum|alt.badge.img+1
  • Author
  • Semi-Pro II
  • January 24, 2023

Tried using the logic that if NEXT uom is not null, then that UOM should display instead of being blank. But I got an error that says “Exception has been thrown by the target of an invocation.”

=IIf(Prev([[SOShipLine.UOM])=[SOShipLine.UOM] and Next([SOShipLine.UOM])<>Null, '',[SOShipLine.UOM])

 

Whatelse can I try? Somebody please, thank you!


aaghaei
Captain II
Forum|alt.badge.img+10
  • Captain II
  • Answer
  • January 24, 2023

try
 

=IIf(IsNull([SOShipLineSplit.LotSerialNbr], '')<>'', IIf(Prev([SOShipLine.TranDesc])=[SOShipLine.TranDesc], '',[SOShipLine.UOM]), [SOShipLine.UOM])

 

or compare previous and current SOShipLine.InventoryID instead of TranDesc


Forum|alt.badge.img+1
  • Author
  • Semi-Pro II
  • January 24, 2023

try
 

=IIf(IsNull([SOShipLineSplit.LotSerialNbr], '')<>'', IIf(Prev([SOShipLine.TranDesc])=[SOShipLine.TranDesc], '',[SOShipLine.UOM]), [SOShipLine.UOM])

 

or compare previous and current SOShipLine.InventoryID instead of TranDesc

Thank you sir, but this error came up

The expression contains the 'SOShipLine' object that is not defined in the current context.

What does this mean?


Forum|alt.badge.img+1
  • Author
  • Semi-Pro II
  • January 24, 2023

try
 

=IIf(IsNull([SOShipLineSplit.LotSerialNbr], '')<>'', IIf(Prev([SOShipLine.TranDesc])=[SOShipLine.TranDesc], '',[SOShipLine.UOM]), [SOShipLine.UOM])

 

or compare previous and current SOShipLine.InventoryID instead of TranDesc

Thank you sir, but this error came up

The expression contains the 'SOShipLine' object that is not defined in the current context.

What does this mean?

Oh I just missed some []. This worked! Really thank you so much for the quick and effective assistance sir @aaghaei !