magnetic fields, current and resistance

How do I determine how much current a wire can safely handle? I made some electromagnets with some coil and 9 volt batteries, but the wire and the batteries get real hot after a minute, which I assume is not good so i don't keep it connected for long. I want to know how much the wire I am using can take. The only thing on the package it came in was what gauge it is, but I thought that related to size not how much it could take. Is there a way to experimentally determine it?

Also is connecting batteries in series or parallel better (for getting more voltage)?

And finally, for the ideal solenoid B=u0in where i is current, and n is turns per unit length: if voltage through the coil is constant then does just adding more turns get canceled out from the decrease in current due to more wire and hence more resistence so B would remain the same?

 PhysOrg.com engineering news on PhysOrg.com >> Researchers use light projector and single-pixel detectors to create 3-D images>> GPS solution provides 3-minute tsunami alerts>> Single-pixel power: Scientists make 3-D images without a camera
 Recognitions: Science Advisor Wire sizing for safety can be found by finding how many circular mils are carrying per amp, and you'd likely want 200 mils as an absolute minimum per amp. Here's a page with a chart near the bottom (and all kinds of info on the way to it) that lists popular gauges and their mils and resistance per foot. http://www.bcae1.com/wire.htm Batteries in series will double voltage capability, batteries in parallel will double current capacity. BUT you have a fixed resistance, and from E = IR you know if you double the voltage the current must double as well which means 4 times the power. Not going to work for you especially if you're already cooking your 9V battery. You're going to be better off in parallel so the batteries can work together to deliver the current. You're voltage through your coil is not going to be constant when overloading a battery like this (getting warm=overload) and usually you can provide many more turns without the resistance changing much. You could get the resistance per foot and find the diameter of a turn and calculate this yourself. Cliff