If that doesn't work (maybe the switch needs the battery detected) you could try putting a resistor that matches the resistance of the battery to simulate it in there, if you're really going for wall-only power. However, PLEASE double-check with someone who knows their electronics because you might just fry some shit.