Skip to content
+1-888-319-3663

COMMUNITY FORUM

Map restriction script

Hal asked 9 years ago
I have a field in my data source named _RECEIVED and I want to restrict the map to only accept fields with a non-Zero value.

I put in the following script for this:

if _RECEIVED <> 0 then return true else return false end if

When I try to validate I am advised that "Error in restriction:  End of statement expected

What am I doing wrong?

Sarvenaz replied 9 years ago

You should not get any syntax error if you write the calculation in multiple lines:

if _RECEIVED <> 0 then
return true
else return false
end if

Regards,

Answers
Best Answer
Hal answered 9 years ago
Thank you very much.  SImple detail overlooked!  Your solution hit the spot.  I don't know how to mark your solution as the answer that closed this thread so I'll mark this response as answer.  Thanks again!  Hal.

If you would like to submit an answer or comment, please sign in to the eOne portal.