Initial value based on one of 2 other fields (Columns)

So I have a sheet that has 3 main columns, “LOT#”, “Barcode”, and “Item”. I have this sheet as a supply’s out and it refers back to the supply sheet to look up items based on the LOT# or Bar code. These have expiration and some have a unique bar code and some just have a LOT#. So, If the Item has a bar code it will fill everything out, if it only has a LOT# i want it to fill the item out.
Here is my problem I set the initial value to the following and set “reset on edit” to on. it changes the item if there is a barcode, but will not change if there is only a LOT#. I have tried so many ways and can’t get it to work.

IF(ISNOTBLANK([_THISROW].[LOT#]),
LOOKUP([_THISROW].[LOT#], “Supply Total”, “LOT#”, “Item”),
LOOKUP([_THISROW].[Barcode], “Supply Total”, “Barcode”, “Item”)

)

remove [_THISROW] in your ISNOTBLANK() part of your expression:

IF(
    ISNOTBLANK([LOT#]),
    LOOKUP([_THISROW].[LOT#], “Supply Total”, “LOT#”, “Item”),
    LOOKUP([_THISROW].[Barcode], “Supply Total”, “Barcode”, “Item”)
)
3 Likes

Thank you so much!! I knew it would be something simple.

1 Like

You’re welcome