Values not receiving to other object

Posted by mysteryminds on 07-Nov-2014 16:45

I'm novice out in RB and I have a question related to the data to be posted from one object to another.

My condition is that when i save data e:g from a Decimal [ DATA TYPE]  from object A

in Object B I would like to use the Field of  Object A which is Decimal type field in a formula field 

The code would be some thing  {!field A} * ({!2334.object A Field } / 10)  - NOTE THAT THIS IS FORMULA (Decimal) 

But my main issue here is even though there is value is field of Object A 

when i validate always it shows " 0" in Object A field 

e.g: 100 * 0/100  = 0 

All Replies

Posted by Orchid Corpin on 07-Nov-2014 17:20


Can you make sure that the quotient value of ({!2334.object A Field } / 10) is not zero? or field {!field A}is not zero too?

Also make sure that the formula field "Return type" is decimal.




Posted by Orchid Corpin on 07-Nov-2014 17:26

Try parsing the values too, something like this:

var num1 = parseFloat("{!2334.object A Field }") / 10;
    num1 = num1 * parseFloat("{!field A}");
    return num1;



Posted by mysteryminds on 07-Nov-2014 17:31

Thanks Orchid

Well I made sure that no where the values are NULL or Zero

and yes Return type is DECIMAL,

My main problem is that its not returning values only from OBJECT A  

Object A

field type  : Decimal

Caliculation location :  


Return type : Decimal

Posted by mysteryminds on 07-Nov-2014 17:58

tried that still it gets value 0

Parsed Formula

001 function wrapper() {

002 /*194500.0 * (0/100)*/ - this is with the previous formula


004 var num1 = parseFloat("0") / 100;

005     num1 = num1 * parseFloat("194500.0");

006     return num1;

007 }

008 wrapper();

I also noted one thing even when i try to just call the field as simple as 

{!R114103128.estimated_tax_rate} the result shows 0 
Am I missing something really silly .....

Posted by Orchid Corpin on 07-Nov-2014 19:11

{!R114103128.estimated_tax_rate} is this record was attached to the current object?



Posted by mysteryminds on 07-Nov-2014 19:24

well i don't seem to understand your perspective "Attached"

All I'm sure of is that is this is a formula(Decimal) field of different object

If you are talking attached as a relation to one record  - Yes it is

As the field value is coming from different tabs of different objects from same record

Posted by Orchid Corpin on 07-Nov-2014 19:51

Sorry for confusing the term, I mean, if you created the formula field from Object B, is the lookup field "R114103128" has value and to debug it rbv_api.println("{!R114103128#id}"); - this should return an integer value and NOT "-1".

In this case you can get something from {!R114103128.estimated_tax_rate}, but

if rbv_api.println("{!R114103128#id}"); returns a -1 value then {!R114103128.estimated_tax_rate} will always 0.



Posted by mysteryminds on 07-Nov-2014 20:13

 this is what i see when i run from debug mode for Id value 

Posted by Orchid Corpin on 07-Nov-2014 20:38

This field "estimated_tax_rate" from "R114103128" should have value unless it is really 0.

Since you already check that part I want to see the real transaction to help me debug on this issue too, can we have screen sharing?

or go to and enter meeting ID

Meeting ID: 176-619-341



Posted by mysteryminds on 08-Nov-2014 02:57

Ooops so sorry missed that out... Please let me know when can we dicsuss on this.. this silly thing is bugging my head out

Posted by mysteryminds on 10-Nov-2014 10:34

[mention:e6fb884e9c7b45a2a638966c06dc0941:e9ed411860ed4f2ba0265705b8793d05]  wonder how... but suddenly the same old code " {!field A} * ({!2334.object A Field } / 10)"  start to work on its own.... really a MIRACLE

If you ask me how I really don't know

Posted by Orchid Corpin on 10-Nov-2014 10:45

That is good to hear!

I also have that kind of situation where I changed all my codes and still didn't work but when trying to put back the old code then it starts working. :)



This thread is closed