Listview not adding value from second activity.
if (edtName.Text != "" && edtDescription.Text != "" && edtDate.Text != "") { Intent intent = new Intent(); string Name = edtName.Text; string Description = edtDescription.Text; DateTime DateDeploy = DateTime.Parse(edtDate.Text);
intent.PutExtra("Name", Name.ToString()); intent.PutExtra("Descritption", Description.ToString()); intent.PutExtra("Date", DateDeploy.ToString()); intent = new Intent(this, typeof(FirstActivity)); //StartActivityForResult(intent, 0); SetResult(Result.Ok,intent); //StartActivity(intent); Finish(); }
For this Second activity I added intent.putExtra for adding value from First activity. And In First Activity I added protected override void OnActivityResult(int requestCode, Result resultCode, Intent data){
string name, desc, datecreated;
name = data.GetStringExtra("Name"); desc = data.GetStringExtra("Descritption"); datecreated = data.GetStringExtra("Date");
//Not Working Here
}
Please, help me to how do i add item from second activity to first activity ListView