FragmentManager.PopBackStack Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| PopBackStack() |
Pop the top state off the back stack. |
| PopBackStack(Int32, PopBackStackFlags) |
Pop all back stack states up to the one with the given identifier. |
| PopBackStack(String, PopBackStackFlags) |
Queues a request to pop back-stack entries by name. |
PopBackStack()
Pop the top state off the back stack.
[Android.Runtime.Register("popBackStack", "()V", "GetPopBackStackHandler")]
public abstract void PopBackStack();
[<Android.Runtime.Register("popBackStack", "()V", "GetPopBackStackHandler")>]
abstract member PopBackStack : unit -> unit
- Attributes
Remarks
Queues a request to pop the top back-stack entry. ExecutePendingTransactions() can execute the request before the application returns to its event loop. On API level 26 and later, the primary navigation fragment's child manager gets the first opportunity to handle the request.
Android reference for android.app.FragmentManager.popBackStack.
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
PopBackStack(Int32, PopBackStackFlags)
Pop all back stack states up to the one with the given identifier.
[Android.Runtime.Register("popBackStack", "(II)V", "GetPopBackStack_IIHandler")]
public abstract void PopBackStack(int id, Android.App.PopBackStackFlags flags);
[<Android.Runtime.Register("popBackStack", "(II)V", "GetPopBackStack_IIHandler")>]
abstract member PopBackStack : int * Android.App.PopBackStackFlags -> unit
Parameters
- id
- Int32
A non-negative identifier returned by Commit(). If no entry has this identifier, no entry is popped.
- flags
- PopBackStackFlags
Use Inclusive to include the matching entry, or None to leave it on the stack.
- Attributes
Exceptions
id is negative.
Remarks
Queues a request to pop entries above the entry with the given identifier. flags controls whether the matching entry is also popped. ExecutePendingTransactions() can execute the request before the application returns to its event loop.
Android reference for android.app.FragmentManager.popBackStack.
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
PopBackStack(String, PopBackStackFlags)
Queues a request to pop back-stack entries by name.
[Android.Runtime.Register("popBackStack", "(Ljava/lang/String;I)V", "GetPopBackStack_Ljava_lang_String_IHandler")]
public abstract void PopBackStack(string? name, Android.App.PopBackStackFlags flags);
[<Android.Runtime.Register("popBackStack", "(Ljava/lang/String;I)V", "GetPopBackStack_Ljava_lang_String_IHandler")>]
abstract member PopBackStack : string * Android.App.PopBackStackFlags -> unit
Parameters
- name
- String
The name of an entry to find. If null and a child manager does not handle the request, this manager pops its top entry, or all entries when flags includes Inclusive.
- flags
- PopBackStackFlags
Use Inclusive to include matching entries, or None to leave them on the stack.
- Attributes
Remarks
Queues a request to pop entries above the named entry. flags controls whether matching entries are also popped. If name is not null and no entry matches it, no entry is popped. ExecutePendingTransactions() can execute the request before the application returns to its event loop. This method does not return a result.
Android reference for android.app.FragmentManager.popBackStack.
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.