Boolean Expression - End of Expression Expected

I want to create a Boolean expression for an If Activity or Decision Node but I keep getting error End of Expression expected. What is wrong with it?

CInt(reviewRow("Overall Satisfaction").ToString)<1
Or CInt(reviewRow("Overall Satisfaction").ToString)>10
Or CInt(reviewRow("ReceptionRating").ToString)<1
Or CInt(reviewRow("ReceptionRating").ToString)>10
Or CInt(reviewRow("RestaurantRating").ToString)<1
Or CInt(reviewRow("RestaurantRating").ToString)>10
Or CInt(reviewRow("GymRating").ToString)<1
Or CInt(reviewRow("GymRating").ToString)>10
Or CInt(reviewRow("PoolRating").ToString)<1
Or CInt(reviewRow("PoolRating").ToString)>10

Hi @DEATHFISH

Try it like that:

CInt(reviewRow("Overall Satisfaction").ToString)<1 _
Or CInt(reviewRow("Overall Satisfaction").ToString)>10 _
Or CInt(reviewRow("ReceptionRating").ToString)<1 _
Or CInt(reviewRow("ReceptionRating").ToString)>10 _
Or CInt(reviewRow("RestaurantRating").ToString)<1 _
Or CInt(reviewRow("RestaurantRating").ToString)>10 _
Or CInt(reviewRow("GymRating").ToString)<1 _
Or CInt(reviewRow("GymRating").ToString)>10 _
Or CInt(reviewRow("PoolRating").ToString)<1 _
Or CInt(reviewRow("PoolRating").ToString)>10

@loginerror Thanks, it worked! Btw, what does the underscore do and how does it solve the problem?

I think it is a readability thing in vb.net
You can either put your entire statement on 1 line or tell it to consider it 1 expression but divide it into separate lines with an underscore :slight_smile:

3 Likes