When an error in a selection equation is correlated with regression equations, then these correlation measures have to be corrected in the likelihood function, otherwise the results will be biased.
Here are a couple of procedures one can use. 1) nlmixed
2) qlim