GP Power Tools has a powerful feature called Company Login Filter. This feature was created to allow the selection of companies to be controlled based on the application configuration used to launch Microsoft Dynamics GP.
It has a number of other features such as controlling the order of the companies listed and optionally showing the database name for the company, but if configured incorrectly it does have the ability to block access to the application by removing access to all the companies.