Can I bypass power adapter or how to connect to light switch instead?

I want to splice the power cable directly to wall switch.