Sam K
Posts: 0
Joined: Sat Sep 08, 2012 6:57 pm

How to use javascript with response mapping?

I have mapped a response to a label in a grid container. The value I get from my json call needs to be trimmed (for example I get back a23-b23-c23, and I just want to display a23) - so if I do value.substring(0,3), I get the right text to put on the Label.

However, when I do this in the Response mapping Javascript - next to the mapped label: Tiggr("mobilelabel21").text(value.substring(0,3)), this value does not appear in my label value.
Any thoughts on how I can fix this? I am wondering if it is the order in which I am updating the label..If there is a better way to handle this let me know..Thanks
Sam

Return to “Issues”