What soundbar?
I have an Insignia, it uses an IR remote so whatever device you're trying to use to turn it on or off should have that capability if yours is like mine. In fact - my TV is also an Insignia, the remote for the TV turns on the sound bar. If you have a universal remote, you might be able to program it to turn the bar on and off.
If you need additional help or have more questions or details to share, please join the site so you can reply in this thread. See
this link for instructions on how to join Android Central.