I have two EdiText fields, name and age I need the name field to get 70% of the line and age at 30%, in xml it's easy to solve this, but in Java code I'm not getting it, does anyone know how to do it? Thank you in advance!
I'm using this code to set the parameters.
LayoutParams param5 = new LayoutParams(LayoutParams.MATCH_PARENT,
LayoutParams.WRAP_CONTENT, X);
nome_edit.setLayoutParams(param5);
Note: I tried to leave the first parameter of LayoutParams at 0 and put a value in place of X but it did not work.