Magnetic fields behave in many of the same ways as electric fields. Could a society develop a magnetic based system of computation before they invent an electric method like modern integrated circuits? If so, what might cause this to happen?
Technically yes, but it would look more like a mechanical clock than a computer.
Electricity and magnetism behave similarly because they are really the same force. The main difference is that magnetism is related to a separation in charge, whereas electricity is just a buildup somewhere.
If you have a block of iron that is magnetic, it will have a magnetic field around it, with north and south poles. However, it won't have an electric charge (unless it's hooked up to a battery or something), because it has the same number of electrons and protons: the movements of the electrons are just aligned in the same direction.
An electrically charged block of iron isn't necessarily magnetic. It just means that it has a certain surplus or deficiency in electrons floating around inside it. Notice that there is no direction- just an amount of charge.
Electricity is great for circuits, because this charge is easy to move around - it's just a buildup of electrons, which are a) very light and b) respond to electric fields, which are easy to create. Moving electrons around is a very easy and fast task, and movements of electrons can be used to control other movements of electrons.
Magnetism, however, doesn't move electrons unless the magnetic item itself is moving. In fact, since magnetism operates on the direction of the field, the components of the circuit would have to be changing direction, ie. rotating. A complex machine with tons of tiny rotating components? Sounds like clockwork. Basically you have a bunch of tiny magnetic switches that rotate around and flip each other, moving small magnetic fields which can be used to influence the movements of more fields.
The problem with this is that magnetic fields, like electric fields, get less strong over a large distance. Electric circuits get around this by moving the source of the field (the electron) until it's close enough to have an effect, which works because electrons don't experience a lot of friction (when they do, it's called resistance and it's pretty minimal on a small scale) and can make it pretty far in a circuit without losing energy. Magnetic switches, though, would be rotating on an axle, and would lose energy to heat and friction.
One way that magnetic fields have been used in computing (a long time ago) is relays, which are just that: tiny magnetic switches. They are activated by an electric current, moving a magnet and flipping a switch closed. That's more of a hybrid magnetic/electric system though.
Basically- electromagnetic fields, when used in the way you're suggesting (complex circuitry) behave as electric fields. To force them to be magnetism would require emphasizing the parameters involved magnetism: orientation and movement, which would make an interesting mechanical/magnetic computer.
It's true that the movement of electrons causes a magnetic field. However, magnetic fields are caused by all kinds of things, many having nothing to do with electrticity. Ferrous magnets, for example, won't shock you with electricity when you pick them up.
The problem is that modern computers run on the flow of electrons, NOT the presence of an electric field
A magnetic field is not the flow of electrons. A very applicable analogy is, "can I turn a water wheel with humidity in the air?" Obviously the answer is no. A magnetic field is analogous to humidity in the air, not the flow of water in a stream. Electricity is analogous to the flow of water in a stream, and therefore you can use it to do work.
Magnetism is not a particle, nor can it be broken down into particles. A "magnetic field" cannot be channeled, amplified, reduced, gated, or any of the other things we do with electrons to compute.
But I can push things with a magnetic field, why can't I push gears?
OK, you could do that, it's the waterwheel effect. But you're not computing with magnetism. You're just hooking a Babbage Engine up to a magnetic waterwheel. You could also hook it up to an actual water wheel and get the same computations. In otherwords, what you have is a mechanical computer, not an electronic computer, a magnetic computer, nor an optronic computer.
Wait... you just said "optronic"
Indeed I did. Photons, like electrons, are particles — kinda. They're voodoo juju, but they have an aspect that acts entirely like charged particles. Consequently I can make reducers, amplifiers, gates, and all the other neato stuff I need for computing. The "wires" (optic channels) are still a bit of a problem, and doing things on the nanometer scales we really want is a bigger problem, but it can be done.
Because I'm not working with a field of energy, I'm working with a particle.
So, I regret, the answer is no. You can't build a "magnetic computer." A mechanical Babbage engine is the best you can do.
but only if the inventing civilization is completely made of Magnetic Monopoles.
Magnetic Monopoles (MM's) are isolated carriers of magnetic charges, much like protons and electrons are carriers of electric charges. In a way, your north carriers can behave like protons or positrons, depending on their charge which is directly proportional to their mass. South carriers can then be antiprotons or electrons.
Something called Magnetricity also exists, but as a less appreciated technology.