ContextStack.Pop 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.
Removes the current object off of the stack, returning its value.
public:
System::Object ^ Pop();
public object Pop ();
public object? Pop ();
member this.Pop : unit -> obj
Public Function Pop () As Object
Returns
The object removed from the stack; null
if no objects are on the stack.
Examples
The following code example demonstrates removing a value from a ContextStack.
// Pop each item off the stack.
Object^ item = nullptr;
while ( (item = stack->Pop()) != 0 )
Console::WriteLine( "Value popped from stack: {0}", item );
// Pop each item off the stack.
object item = null;
while( (item = stack.Pop()) != null )
Console.WriteLine( "Value popped from stack: "+item.ToString() );
' Pop each item off the stack.
Dim item As Object = stack.Pop()
While item IsNot Nothing
Console.WriteLine(("Value popped from stack: " + item.ToString()))
item = stack.Pop()
End While
Applies to
GitHub पर हमारे साथ सहयोग करें
इस सामग्री का स्रोत GitHub पर पाया जा सकता है, जहाँ आप समस्याएँ बना और समीक्षा भी कर सकते हैं और अनुरोध खींच सकते हैं. अधिक जानकारी के लिए, हमारे योगदानकर्ता गाइड देखें.