Activity.StartActivityForResult Activity.StartActivityForResult Method

Definition

Overloads

StartActivityForResult(Intent, Int32) StartActivityForResult(Intent, Int32)

M:Android.App.Activity.StartActivityForResult(Android.Content.Intent,System.Int32,System.Int32)

StartActivityForResult(Type, Int32) StartActivityForResult(Type, Int32)
StartActivityForResult(Intent, Int32, Bundle) StartActivityForResult(Intent, Int32, Bundle)

Launch an activity for which you would like a result when it finished.

StartActivityForResult(Intent, Int32) StartActivityForResult(Intent, Int32)

M:Android.App.Activity.StartActivityForResult(Android.Content.Intent,System.Int32,System.Int32)

[Android.Runtime.Register("startActivityForResult", "(Landroid/content/Intent;I)V", "GetStartActivityForResult_Landroid_content_Intent_IHandler")]
public virtual void StartActivityForResult (Android.Content.Intent intent, int requestCode);
abstract member StartActivityForResult : Android.Content.Intent * int -> unit
override this.StartActivityForResult : Android.Content.Intent * int -> unit

Parameters

intent
Intent Intent

The intent to start.

requestCode
Int32 Int32

If >= 0, this code will be returned in onActivityResult() when the activity exits.

Exceptions

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

StartActivityForResult(Type, Int32) StartActivityForResult(Type, Int32)

public void StartActivityForResult (Type activityType, int requestCode);
member this.StartActivityForResult : Type * int -> unit

Parameters

activityType
Type Type
requestCode
Int32 Int32

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

StartActivityForResult(Intent, Int32, Bundle) StartActivityForResult(Intent, Int32, Bundle)

Launch an activity for which you would like a result when it finished.

[Android.Runtime.Register("startActivityForResult", "(Landroid/content/Intent;ILandroid/os/Bundle;)V", "GetStartActivityForResult_Landroid_content_Intent_ILandroid_os_Bundle_Handler", ApiSince=16)]
public virtual void StartActivityForResult (Android.Content.Intent intent, int requestCode, Android.OS.Bundle options);
abstract member StartActivityForResult : Android.Content.Intent * int * Android.OS.Bundle -> unit
override this.StartActivityForResult : Android.Content.Intent * int * Android.OS.Bundle -> unit

Parameters

intent
Intent Intent

The intent to start.

requestCode
Int32 Int32

If >= 0, this code will be returned in onActivityResult() when the activity exits.

options
Bundle Bundle

Additional options for how the Activity should be started. See StartActivity(Intent, Bundle) for more details.

Exceptions

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to