community
cancel
Showing results for 
Search instead for 
Did you mean: 

Alteryx designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.

Error Message with File Browser

Highlighted

I am using the File Browse tool with Dynamic Input. I want to produce an error IF an incorrect sheet is selected.

Below is the formula I am trying to use within the Error Message tool, but it doesn't seem to be working properly. Also how can i get it to stop running if there is an error?

Contains([#1], "RM")
OR
Contains([#1], "SO")

Capture.JPG

Alteryx Certified Partner
Alteryx Certified Partner

Trying the following expression:

 

contains([#1],"|'RM$'")!=-1

OR 

contains([#1],"|'SO$'")!=-1

 

The Contains( function will return the value "-1" if the expressions is true and the field is not formatted as a Boolean. Adding the |' and $' makes sure you're only looking at the sheet name. Otherwise, the input "Filname_RM.xlsx|||'Wrong$'"would be valid.

Quasar

+1 to @CharlieS 's formula

 

You can also look into the Test tool to stop the workflow if certain conditions are not met.

Labels