I am doing some calculation but unable to parse a string into int or even in float.I searched for solution and i read it somewhere there must be a empty string but i checked my
put a check before doing Integer.parseInt like
final int a = (height == null || height.trim().equal("") ? 0 : Integer.parseInt(height));
Also you need to add this code for getting the height value from edittext inside onclick listener as when in OnCreate control will not have any value apart you set some default value in layout.xml as it is just created