Top  Previous  Next


The LOGTO command moves to an alternative account directory without leaving QM.









nameis the name of the target account. This may be an account name as in the ACCOUNTS register of the QMSYS account or the pathname of the new account directory.


RESETcauses the command processor to discard all active paragraphs, menus, etc.



If the user has account restrictions imposed on them (see Application Level Security), name must be an account name, not be a pathname.



Multiple accounts are useful where there are several distinct projects. They can also be used to separate development and production versions of an application.


The LOGTO command closes the current VOC, moves to the account directory specified by name and opens the VOC of the new directory.


If the RESET keyword is present, any active programs, menus, etc at the current command processor level are discarded. This is particularly useful when using LOGTO in a menu.


Use of RESET ALL discards all active programs, menus, etc and returns the bottom level command processor. If a higher level command processor had been started from a program that used the TRAPPING ABORTS option of the QMBasic EXECUTE statement, the program will not trap this action. The RESET ALL mode of LOGTO is not available in QMClient sessions.


If the VOC of the current account contains an executable item named ON.LOGTO, usually a paragraph, this will be executed before moving to the new account.


If the VOC of the new account contains an executable item named LOGIN, this will be executed on arrival in the new account.


If the LOGTO action is successful, the account name as reported by the WHO command or returned as the value of the @WHO system variable is set to the new account.


LOGTO will fail if name cannot be found or is not a valid account.


The QUIT command to leave QM will return to the original account directory before exiting.