I am trying to put a try-catch around an assign activity for something which won’t necessarily need assigning. I’m scraping customer information from different pages of a website and sometimes the field ‘CompanyName’ doesn’t appear.
I read that if I put that inside a try-catch that it would skip over it if it is one of these instances where it doesn’t apply. However, I keep getting an error of ‘Assign: The given key was not present in the dictionary.’ and the catch not working.
Am I doing something wrong with it? Is there a specific exception type I should be selecting for this? On the ‘finally’ section section, I’ve made it so that CompanyName gets assigned to ‘No Company Name’ instead, but this doesn’t work either.
I’m a bit stuck and would appreciate any input! Thank you.