Advertisement
Guest User

Untitled

a guest
Jul 16th, 2019
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. Intent intent = new Intent(this, MostrarDatos.class);
  2. intent.putExtra("usuario", edsuario.getText().toString());
  3. startActivity(intent);`
  4.  
  5. try{
  6. Bundle bundle = new Bundle();
  7. bundle = getIntent().getExtras();
  8. txt1.setText(bundle.getString("usuario"));
  9.  
  10. }catch(Exception e){
  11. Toast.makeText(getApplicationContext(), "¡A ocurrido un error!", Toast.LENGTH_SHORT).show();
  12. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement