Set it above 17,000'.
If you wait until you're above 18,000' you can't level off at FL180.
Passing 11,000' for FL230 you stay with local altimeter until above 17,000'. At that point you've left the low altitude structure (<17,999') and will use 29.92 for all altitudes.