Skip to main content
Solved

Visible Expression for string inside of InventoryID


Forum|alt.badge.img

Hi all,

 

I need a VisibleExpr that flips visibility based on a string inside of our InventoryID -- if an InventoryID contains “-STRING-”, then flip this text on.

 

=iif(([AMProdItem.InventoryID]='-STRING-'),false,true)

 

Unfortunately, I don’t know how to write the query so I’m asking if it CONTAINS, not EQUALS.

How do I craft the query to see if the InventoryID contains ‘-STRING-’?

Best answer by jinin

Hi @swartzfeger ,

 

Could you try like the below,

IIf(InStr([AMProdItem.Descr], '-STRING-') > 0, True, False)

View original
Did this topic help you find an answer to your question?

2 replies

jinin
Pro I
Forum|alt.badge.img+11
  • Pro I
  • 701 replies
  • Answer
  • November 7, 2023

Hi @swartzfeger ,

 

Could you try like the below,

IIf(InStr([AMProdItem.Descr], '-STRING-') > 0, True, False)


Forum|alt.badge.img
  • Author
  • Freshman II
  • 172 replies
  • November 7, 2023
swartzfeger wrote:

Hi all,

 

I need a VisibleExpr that flips visibility based on a string inside of our InventoryID -- if an InventoryID contains “-STRING-”, then flip this text on.

 

=iif(([AMProdItem.InventoryID]='-STRING-'),false,true)

 

Unfortunately, I don’t know how to write the query so I’m asking if it CONTAINS, not EQUALS.

How do I craft the query to see if the InventoryID contains ‘-STRING-’?

Perfect Jini, thank you! I’m not familiar with C# but InStr makes sense now… thank you!


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings