In order to correct the path to the communication DLL, you can manually edit the path by double clicking it and editing it.
Now the important part: you MUST then press ENTER!!! otherwise the change will not be set and the old path will remain!
Press OK and the new path is set.

- in Codesys select "Online / Communication Parameter"
- click "New"
- give the new connection a name
- select the type of connection (usually "STW_FF_CAN")
- click "OK"
- verify the path points to the correct file. If not, manually correct the path
- when finished typing the path, press ENTER !
- click "OK"
=> The path is now changed.