Use the getKey() function. Bear in mind that all keys need to match exactly in both apps so that you don’t get errors.
I think there might be ways, but another option could be to use a Java snippet to map the enum for you.
It requires no if/elsing in the mapping and grows with new values. Check this blog for it's implementation: String to enum: Java snippet - Dennis Kho's Mendix Blog (mxblog.nl)
Jannes way works perfectly :)
But I’ll definitly look at the post Louis.
Thanks for the input ;)-