I can place the following code inside the MainActivity and get the correct toast message
Toast.makeText(this@MainActivity, “This works”, Toast.LENGTH_LONG).show()
However, if I place the same line in another file that contains a class, I get an error that @MainActivity is unresolved. I think I need to make MainActivity global, but I am not sure how to set that. Any suggestions would be appreciated.