12V AC adaptors are relatively inexpensive, but 24V AC adaptors are often more than double the price. By connecting two 12V adaptors, you can achieve the 24 volts of current you need without the extra cost. You will be connecting the two adaptors in series, which combines the voltage of the two adaptors into the total of both without increasing the amperage. If both individual adaptors provide 6 amps, for example, they will still provide 6 amps total when connected in series.
Unplug both AC adaptors to avoid risk of electric shock.
Cut the wire of the first AC adaptor a few inches from the connector. Mark the positive and negative wire on both ends and strip all four exposed wires.
Cut the wire of the second AC adaptor a few inches from the connector. Mark the positive and negative wire on the adaptor end. You will not need the second connector.
Twist the positive wire coming from the first adaptor to the negative wire coming from the second adaptor. Twist a wire nut around both to seal the connection.
Twist the negative wire from the first adaptor to the negative wire of the connector. Twist a wire nut around both to seal the connection.
Twist the positive wire from the second adaptor to the positive wire of the connector. Twist a wire nut around both to seal the connection. Plug both adaptors into the wall. Your connector will now supply 24V DC power.
If the initial connector does not fit the device you need to power, replace the original connector in the steps above.
Never touch bare wires when the adaptors are plugged into the wall, as there is a risk of electric shock.