When laying at SP you need to be aware of a few things:
As Mark said, that you cannot use actual_sp in the condition as it is zero until the BSP is resolved momentarily after the off. So if you said actual_sp < 5 it would fire (as the actual_sp is always zero until the start) but be meaningless.
You can make an estimate of final SP by using near of far SP, as Mark suggested, or guess at the eventual SP from the current back or lay price but there are no guarantees! I use lay at SP to green up backs placed earlier, and have tried using back price, or an average of current back and lay prices at a few seconds to go.
The other thing to note is that the stake when laying at SP will not be the value in the "Amount" box in the trigger! Confusing. When laying at SP you define the amount you are putting at risk (the liability). So if you put £10 in the amount box and the final SP is 6 then the stake will be £2 (ie = 10 / (6-1) ).
THE AMOUNT HAS TO BE OVER £10 to meet
BetFair SP rules - anytthing lower will be ignored.
The price box in the lay at SP trigger defines the maximum price you will allow. I leave this blank as I have already stated what I willl be liable for in the Amount box.
The trouble is that races can be late starting, a few minutes is often seen but this can be up to 30 mins or more if there is a big fall in a previous race. Your SP bet waits for the eventual start and cannot be cancelled.
Prices can vary a lot in that time. For this instance I have a trigger that checks every 30 seconds after the intended start and trims the lay at SP amount accordingly based on how the back price is moving . To avoid the mininimum £10 mentioned above for these bets I use "Take SP" not 'lay at SP' for these trim bets (with a price of 1.01 so they are deliberately not matched before the off) but if there is a market suspension before the start these are cancelled anyway - so there is no totally infallable way of doing it.
Sorry for the long post - I hope this helps.