How to stop processing of the same order once the order is cancelled ? I\'m using paypal payment method,While placing the order from paypal if I cancel the order from the paypal
i think problem with you status is change but the state is not changing try below code..
$order->setData('state', Mage_Sales_Model_Order::STATE_CANCELED);
$order->setStatus("canceled");
$history = $order->addStatusHistoryComment('', false);
$history->setIsCustomerNotified(false);
$order->save();