Xamarin forms run on one activity, which is most similar to your main activity.
There are two sample projects that show you how to communicate between native and parts of the code form, which can be found here.
However, to answer your question, you would do something like the following
private const int MyRequestCode = 101; //Start activity for result var contactPickerIntent = new Intent(Intent.ActionPick, Android.Provider.ContactsContract.Contacts.ContentUri); context.StartActivityForResult(contactPickerIntent, MyRequestCode);
and then in your main action (activity that initializes the application of the xamarin form (using global::Xamarin.Forms.Forms.Init(this, bundle); )
protected override void OnActivityResult(int requestCode, Result resultCode, Intent data) { if (requestCode == MyRequestCode && resultCode == Result.Ok) { } }
Johan source share