Title: Getting raw value (with format)
Last modified: March 18, 2025

---

# Getting raw value (with format)

 *  Resolved [rotertal](https://wordpress.org/support/users/rotertal/)
 * (@rotertal)
 * [1 year, 2 months ago](https://wordpress.org/support/topic/getting-raw-value-with-format/)
 * Dear CFF-Team,
 * I’m trying to get the raw value from one cff-field to another cff-field:
 * (function(){
   switch(fieldname121) {case 1: return fieldname57; break;case 2: 
   return fieldname58; break;case 3: return fieldname59; break;}})();
 * (function(){
   switch(fieldname121) {case 1: getField(fieldname107|n).setVal(fieldname57);
   case 2: getField(fieldname107|n).setVal(fieldname58);case 3: getField(fieldname107
   |n).setVal(fieldname59);
 * }
   })();In every case it only grabs the (first) value. How can I get the raw value(
   with the entire format like 15%, etc.)? I know that it works with html-fields
   but then I’m having troubles to execute the function.King regards!

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

 *  Plugin Author [CodePeople2](https://wordpress.org/support/users/codepeople2/)
 * (@codepeople2)
 * [1 year, 2 months ago](https://wordpress.org/support/topic/getting-raw-value-with-format/#post-18367362)
 * Hello [@rotertal](https://wordpress.org/support/users/rotertal/)
 * Thank you so much for using our plugin. The plugin preprocesses the fields’ values
   in the equations to use them in mathematical expressions. However, you can use
   the `|r` modifier to use the field’s raw value without preprocessing.
 *     ```wp-block-code
       (function(){switch(fieldname121) {case 1: return fieldname57|r; break;case 2: return fieldname58|r; break;case 3: return fieldname59|r; break;}})();
       ```
   
 * Best regards.
 *  Thread Starter [rotertal](https://wordpress.org/support/users/rotertal/)
 * (@rotertal)
 * [1 year, 2 months ago](https://wordpress.org/support/topic/getting-raw-value-with-format/#post-18367373)
 * Perfect, thank you so much!

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

The topic ‘Getting raw value (with format)’ is closed to new replies.

 * ![](https://ps.w.org/calculated-fields-form/assets/icon-256x256.jpg?rev=1734377)
 * [Calculated Fields Form](https://wordpress.org/plugins/calculated-fields-form/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/calculated-fields-form/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/calculated-fields-form/)
 * [Active Topics](https://wordpress.org/support/plugin/calculated-fields-form/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/calculated-fields-form/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/calculated-fields-form/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [rotertal](https://wordpress.org/support/users/rotertal/)
 * Last activity: [1 year, 2 months ago](https://wordpress.org/support/topic/getting-raw-value-with-format/#post-18367373)
 * Status: resolved