Assigning multiple based on extraction

Hello I have a robot that extracts alot of information ( only strings)
Then its assigning them to a variable based on what the string contains/ startswith.
Currently am I using a bunch of if statements. But wondered if there was a smarter method for this as my proceedure now its not very handy as I have over 30 if statments and counting.

Thanks in advance

Hi @langsem

Please refer to below best practice.

1 Like

uhm not quite right. I each if statement i have an assignment. So I would need some sort of switch, but same time that wont work as some of the tasks are not just assignment they are perform different tasks aswell.