Inductance

When electrical current passes through a wire, it generates a magnetic field around the wire. Likewise, a changing magnetic field will generate an electrical current in any wire passing through the field. This principle is known as inductance, and it's used frequently in electronics. All radio transmisson is based on inductance, for example. Motors, generators, and relays rely on the principle as well.

There is a principle called the Right-Hand Rule that explains the relationship of electrical to magnetic forces, as follows:

Wire with compass needle showing direction of magnetic field when current flows from bottom to top of this image.

A handy way to remember the right-hand rule. Thumb points in the direction of the current, fingers point in the direction of the magnetic field. Doesn't work with the left hand.

Direction of force exerted on a current-carrying wire in a magnetic field. This illustrates why motors turn. B is the direction of the magnetic field, I is the direction of the current, and F is the direction of the force.

images from Physics:Principles with Applications, Douglas C. Giancoli, ©1980 Prentice-Hall.

Rich Miller found this link to a page explaining inductors and the right-hand rule, which they refere to a the left-hand rule, because they refer to the direction of flow of electrons, not the flow of charge.