// the save button public void btnSave_click(object sender, EventArgs e) { TreeNode foundNode = myTree.findNode(int.Parse(txtKey.Text)); if (foundNode != null) { DisplayAlert("node Saved", foundNode.ToString(), "Okay"); saveList.addRight(foundNode); lblSaveList.Text = saveList.getData().ToString(); } else { DisplayAlert("cant save", "no node found", "Okay"); } }