Well then it looks like you need to do some troubleshooting to find out what parts of the circuit are active with the power off and on and narrow down your search to the differences in the above two cases. Probably only one or two switches in play, so should not be too hard to find out which is acting up.

For example, put the window into the position where is stops and check the voltages on the relay module connector. Do this with the power off and on and see which are different.