Look man, sure, but you cant be surprised youre having hard time.
Depends on your alt, your speed, enemy alt and enemy direction.
Coming straight at you, while both of you are at 8km alt? 25-30ish km.
You at 8km alt when enemy is hugging the deck?
Sub 10km so that the missile comes at steep angle and ignores multipathing.
Anything in between? 20km or less.
Dont bother to fire at enemies going cold or about to enter the notch.
TWS or TRACK while scan gives you benefit of hardlock (able to guide in missiles though datalink) without triggering the enemy RWR that he got hardlocked.
You dont have to hardlock the enemy with TWS, but it can be more beneficial to hardlock him if there are lot of radar pings etc. and you want the radar to keep tracking the specific enemy.