Margin call is calculated at any time. But the market price of a stock is not one point, there are several sample points during a time period (say 5 minutes) the extreme price are filtered (100000) and the rest's average price is used to decide margin call. Since Margin call is enforce at around 20% of account value, normally it is safe to trigger a sale to protect the account value being positive after sale execution.