A magnetic field can be produced by
A moving charge and changing electric field both produces magnetic field.
Can the polarity of magnetic field produced by a current carrying solenoid can be reversed by reversing the ends of the solenoid ie, by connecting upside down?