This is quite an undocumented feature, here is how it works:
Show login screen (without logging out):
Switch current user (replace 501 with the correct UID):
Via Shell this way:
Useful for an automator action for example:
When editing text or code it is quite often very useful to jump to the beginning or the end of a line, or to move the cursor one page up or down..
Unfortunately the keys dedicated to this task (home/end/pageup/pagedown on a windows-pc) have got a different meaning on a mac: Page up/down scroll one page up/down – without moving the caret (cursor), home/end move to the beginning/end of a document – also without moving the insertion point.
The Code is below, should be self-explanatory.
More information found here:
blog.plasticsfuture.org »