Android Question Converting from DIP to %X in code

AlexOfOz

Active Member
Licensed User
Hello. I can't find reference in the help.

I am trying to convert my "dip" values to %x ... %y values in the code. I get the left, width, top, height values - easy - apply a conversion routine to them to get the percent value - easy. But then when I try to apply them I get a NOT A STRING or similar error.

In other words, let's say my value after converting is 30, which I want to make 30%x. How do I turn that into a correct value to apply to the item?

I've tried many, many variations of trying to convince the program to accept it. The confusing thing for me is that when I type up "30%x", it accepts it readily. But when I build "30%x" and try to apply it, it is rejected. What am I doing wrong?

BTW, Google have thanked me for pointing out a failure in their process, to do with publishing for children under the age of 13. They rejected my app; I appealed and they accepted my appeal and thanked me for showing them how to improve their process.
 
Top