I am NSOpenPanel to select a file or folder from a user\'s machine. But when the user clicks \"open\" the cursor is at the beginning of the path that shows up in the text field
In Swift, since it's 2015:
self.textField.moveToEndOfDocument(nil)