java - startActivity not working on onCreateView -


oncreateview

i created button click function called

btnclick.setonclicklistener(new onclicklistener() { intent redirect = new intent(getactivity().getapplicationcontext(), mobilerecharge.class); startactivity(redirect);` } 

also androidmainfest.xml created

<activity android:name=".mobilerecharge"> </activity>` 

but when running code giving "unfortunality application stopped" error. kindly me in regards.

see log cat: java.lang.runtimeexception: binary xml file line #9: must supply layout_width attribute. check mobilerechargue xml layout, in layout tag, must specify layout_width attribute.


Comments

Popular posts from this blog

javascript - Jquery show_hide, what to add in order to make the page scroll to the bottom of the hidden field once button is clicked -

javascript - Highcharts multi-color line -

javascript - Enter key does not work in search box -