Not strictly railroad, but many streetcar lines used either electric sensors in the trolley line, or inductive sensors, to allow the motorperson to select tracks at an intersection where there was a switch.
NYC subways also have 'route selectors' at some stations, where the motorperson can hit a button for a route.
Other systems, the routing is done via computer, or, by a dispatcher at a control center. Some RRs still use towers at some interlockings, and the crews there will select routes as trains go by. These designs have systems that prevent trains from being routed incorrectly, or routings changed while trains are going over the switches, thus the term 'interlocking'. This could be mechanical, electric, or computerized