Hello Magento Friends,

In today’s blog, we will learn How to Delete a Specified Order Status Comment in Magento 2?

In Magento 2, an order status comment is a note or message that can be added to an order to provide additional information or updates about its status. These comments can serve as a communication tool between different persons involved in order processing, helping to track the history and progress of the order.

Admin can create custom order status, which needs explanation. Here comes the need for adding order status comments in Magento 2.

If you have unnecessary order status comments, it is advisable to delete them. You can delete specified order status comments in Magento 2 using the below method.

Steps to Delete a Specified Order Status Comment in Magento 2:

Step 1: Create a root script to Delete a specified order status comment at the below file path

magento_root_directory\Deletecomment.php

Add the code as follows

Output:

Before running script:

before

After running script:

after

Conclusion:

This way, you can delete order status comments in Magento 2. Share the article with your friends and stay updated with us for more Magento 2 solutions.

Happy Coding!

Click to rate this post!
[Total: 0 Average: 0]