frankly, I have no idea what you are asking.
First, what year is your car? That helps us know what security system you are working with.
Second, re-phrase your question so we can understand. You say "...it goes away after I turn the key off and start it up." This doesn't make any sense. When you turn the key off, the engine dies. You have to turn the key (ignition) on before you can start it up. BMW uses key positions. For example, in my 98 750iL, position 0 allows removal of the key from the lock. Position 1 unlocks the steering column and will allow you to turn on the radio. Position 2 turns on all electircal systems. Position 3 is a momemtary position and egnages the starter motor until the engine starts. The engine will not run unless the key is in position 2.