If I am right it sounds like you are trying to interface your RPi to some external hardware - which in this case is one key on a pocket calculator, however the same principle can apply to other situations e.g. a battery operated remote control to operate some mains equipment which it is not realistic (or safe unless you really, really, really know what you are doing ⚡☠⚡) to connect to directly.
To answer your immediate question the current applied to the base of a junction (or bipolar) transistor flows through the (positively-biased) base-emitter junction where it enables a much larger current to throw across the (reversed-biased) collector-base junction and then both currents pass through the emitter.
What this means though is that - as you have realised - to use a transistor as a switch/controlling element in another circuit there needs to be two connections to that circuit in order for things to function. This is why you will often hear of the requirement to connect the 0 volts or ground connections together of the RPi and the other thing that you wish to control.
However this is only a viable means of getting the RPi to control something if one side of the switch you wish to replace/bypass/override is connected to a fixed voltage - like a power supply or ground line. In reality it is very likely that instead the keypad of something like a calculator has a matrix arrangement where both sides of each switch are connected to a microprocessor and one side (row or column) of the matrix is driven one line at a time high or low whilst all the others are kept in the opposite state and the other side (column or row) is monitored to see which lines go to that state.
In order to connect to this the most straightforward way is to use a relay that is driven by a transistor in the manner I show below in which SW15 represents the one button/switch that you wish to have paralleled by the NO (normally open) contacts of the relay, which when the transistor is switch on briefly with a pulsed high GPIO signal will close as if the button on the calculator was pressed...
U3 is a mock up of the brains in the calculator and shows a few lines connected to a representation of a matrix of buttons (only 16 in this case but it is just a demonstration!) - no power supplies in the calculator are shown because a relay is the one situation where no other connections apart from the two for the contacts are used - this is an arrangement that is known as a volt-free contact because, other than for safety reasons involving high voltage or high current situations, there is no linkage back to the controlling circuit in terms of the voltages in the two parts (coil and contacts) of the relay.
simulate this circuit – Schematic created using CircuitLab