Solidity: Disable Buying and Selling if CurrentPrice is below LastTransactionPrice?

Is it possible in Solidity to compare
LastTransactionPrice with CurrentAsk & CurrentBid?

then
Disable Buying/Selling if the price (Ask/Bid) is below LastTransactionPrice?

Thank you!