Can't locate element with dynamic id in C#

On the end is code that uses js to click on object.
can be implemented as custom keyword.