Using an absolute layout is not recommended as others have said (frame layout or relative layout may be better), but if you absolutely must use it, you can use the following bit of code to keep it from tossing warnings right above the offending code: