Title: Adding some custom code for a Cell
Last modified: March 28, 2019

---

# Adding some custom code for a Cell

 *  Resolved [prodograw](https://wordpress.org/support/users/prodograw/)
 * (@prodograw)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/adding-some-custom-code-for-row-cell/)
 * i have set up the export settings to how i wish now
 * I have 11 columns (A to K) and my last column is parcel amount which is a divisible
   number based on column 10 (cart weight) plus it rounds up to nearest whole number
 * I would like to export it as a csv but before export i would like to hook into
   the plugin and for column K i would like to add what i would normally do on a
   spread sheet for it
    `=ROUNDUP((J2/25),0)`
 * is this achievable
    -  This topic was modified 7 years, 2 months ago by [prodograw](https://wordpress.org/support/users/prodograw/).
    -  This topic was modified 7 years, 2 months ago by [prodograw](https://wordpress.org/support/users/prodograw/).
    -  This topic was modified 7 years, 2 months ago by [prodograw](https://wordpress.org/support/users/prodograw/).

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Author [algol.plus](https://wordpress.org/support/users/algolplus/)
 * (@algolplus)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/adding-some-custom-code-for-row-cell/#post-11369089)
 * Hello
 * Please, follow to this topic [https://algolplus.freshdesk.com/support/solutions/articles/25000016635-add-calculated-field-for-order-](https://algolplus.freshdesk.com/support/solutions/articles/25000016635-add-calculated-field-for-order-)
 * You should use $order methods, more [https://docs.woocommerce.com/wc-apidocs/class-WC_Order.html](https://docs.woocommerce.com/wc-apidocs/class-WC_Order.html)
 * thanks, Alex
 *  Thread Starter [prodograw](https://wordpress.org/support/users/prodograw/)
 * (@prodograw)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/adding-some-custom-code-for-row-cell/#post-11369542)
 * Thanks Sorted !
 * help for anyone else that needs its i needed to generate package ammounts based
   on weight
 * below is what i used
 *     ```
       add_filter('woe_get_order_value_total_weight_items',function ($value, $order,$fieldname) {
   
         $value = round($value/25,0,PHP_ROUND_HALF_UP);
   
         if ($value < 1){
          return 1;
         }
         return $value;
       },10,3);
       ```
   
 *  Plugin Author [algol.plus](https://wordpress.org/support/users/algolplus/)
 * (@algolplus)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/adding-some-custom-code-for-row-cell/#post-11369661)
 * you’re welcome

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Adding some custom code for a Cell’ is closed to new replies.

 * ![](https://ps.w.org/woo-order-export-lite/assets/icon-256x256.png?rev=1365554)
 * [Advanced Order Export For WooCommerce](https://wordpress.org/plugins/woo-order-export-lite/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woo-order-export-lite/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woo-order-export-lite/)
 * [Active Topics](https://wordpress.org/support/plugin/woo-order-export-lite/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woo-order-export-lite/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woo-order-export-lite/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [algol.plus](https://wordpress.org/support/users/algolplus/)
 * Last activity: [7 years, 2 months ago](https://wordpress.org/support/topic/adding-some-custom-code-for-row-cell/#post-11369661)
 * Status: resolved