Manual trans can be towed with transmission in Neutral, automatics can not, transfer case needs to be in Neutral.
Rangers with 4x4 electric shift did not have Transfer case Neutral as a selection, even though it is there as one of the 4 position in the transfer case.
Only 2WD, 4high and 4low were available
2001 and up Rangers used a different type of 4WD controller and there are Kits to add Neutral as a transfer case selection.
1997 Ranger used GEM(generic electronics module) as the 4WD controller, and I don't remember a kit for that, but there might have been.
It would require Ford Dealer to reprogram GEM to add Neutral as a shift point, but not sure if they ever did that.
You can get Driveline disconnects, operated from the cab, so leave it in 2WD and slide rear driveline(disconnect it) for flat towing
Yes, manual transfer case would have Neutral
Or add a Shiftster in place of the electric shift motor for towing, you can add Neutral detent to those
Building your own electric Neutral switch would be doable and not all that complicated but would require good electrical skills to wire it up
Electric shift motor info here:
http://www.explorerforum.com/forums/index.php?threads/how-to-rebuild-4x4-shift-motor.123542/
How it works is pretty straight forward
4x4 controller sends shift motor 12v/grd to move it one way and then grd/12v to move it the other way, so just like electric motor for power windows up and down.
The shift motor has 4 contacts(contact wheel) that rotates as the motor turns the shift rod into its 3 pre-set positions, 2H, 4H, and 4L
Controller "knows" what position transfer case is in by these contacts being open or closed
In the picture in above article Neutral is directly across from 2H, between 4H and 4L, it is not marked but is there, so it is just another position for the contact wheel.
So you could highjack motor control and add an LED to ID when transfer case was in Neutral