Error with findViewById in email sending class per application

Asked

Viewed 46 times

0

I’m developing an apk where there are forms that will be sent by email. Hence my class for window change was like this:

erro By adding the methods needed for me to send emails directly from my application, I found these errors: inserir a descrição da imagem aqui

erro3

  • 2

    To assign your context would be this way: context = Solicitacoes.this!

  • Solicitations is a Fragment?

  • was in Fragment.. then I put in Activity, I managed to run without bugs, however it is not sending email

1 answer

1


You just need to add your View before findViewById

Button login = (Button)view.findViewById(R.id.enviar);
  • It has nothing to do with the error presented but I think you’re right, that’s really the problem.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.