I'm getting a 'method range of object global' failed on that line. Any suggestions on how I can amend this?

Thank you