Hi everyone,
I have a lookup data table where the lookup variable is based on a report where a user picks one of two options. Sometimes that entry isn’t found, and in those cases I want to try the other option.
It runs through several lines on the report before it comes across one where it can’t match the entry.
Then it always crashes.
When I set up the if statement after the lookup, I tried a few things and nothing works:
- IF: str_LookupResult = “”
- IF: string.isnullorempty(str_LookupResult.trim)
- IF str_LookupResult is nothing
all of these return an “Object reference not set to an instance of the object” error highlighting the “If”.
I tried doing an assign before the lookup, declaring str_LookupResult = “something”,
then setting my IF: "str_LookupResult = “something” " in case it just didn’t touch it when it returns nothing… still get the same error message. I’m very confused.
What does the lookup data table return if it doesn’t match anything in the table?
Thanks,
Ryan