i'm working on old project built on eclipse , having opened in android studio. built version 1.7, i'm on 1.8, having tried 1.7 no success.
my main problem 3 following errors:
float size = (float) float.parsefloat(v.gettag(r.string.size));
error:
error: error:(228, 71) java: incompatible types: java.lang.object cannot converted java.lang.string
code: int pos = (int) v.gettag(r.string.pos);
error: error:(229, 49) java: incompatible types: java.lang.object cannot converted int
code:
int parentpos = (int) v.gettag(r.string.parentpos);
error:
error: error:(234, 63) java: incompatible types: java.lang.object cannot converted int
i know trying convert object integer. i've tried several possible solutions, had no luck. possible changes in code cannot thing about?
thanks!
v.gettag(r.string.size)
returns object
. object. need cast explicitly string
float size = (float) float.parsefloat((string)(v.gettag(r.string.size)));
the second , third weird me. casting object
int
, should cause first casting integer
, , call intvalue()
on casted object.
by way, android doesn't support java 1.8
Comments
Post a Comment