ContextUtil.EnableCommit Methode

Definitie

Hiermee stelt u de consistent bit in true en de done bit false in de COM+-context.

public:
 static void EnableCommit();
public static void EnableCommit();
static member EnableCommit : unit -> unit
Public Shared Sub EnableCommit ()

Uitzonderingen

Er is geen COM+-context beschikbaar.

Voorbeelden

In het volgende codevoorbeeld wordt de methode aangeroepen EnableCommit .

[Transaction(TransactionOption::Required)]
public ref class ContextUtil_EnableCommit: public ServicedComponent
{
public:
   void Example()
   {
      // Set the consistent bit to true and the done bit to false for the
      // current COM+ context.
      ContextUtil::EnableCommit();
   }
};
[Transaction(TransactionOption.Required)]
public class ContextUtil_EnableCommit : ServicedComponent
{
    public void Example()
    {
        // Set the consistent bit to true and the done bit to false for the
        // current COM+ context.
        ContextUtil.EnableCommit();
    }
}
<Transaction(TransactionOption.Required)>  _
Public Class ContextUtil_EnableCommit
    Inherits ServicedComponent
    
    Public Sub Example() 
        ' Set the consistent bit to true and the done bit to false for the
        ' current COM+ context.
        ContextUtil.EnableCommit()
    
    End Sub
End Class

Opmerkingen

Indien gevraagd, zal de COM+-context de huidige transactie doorvoeren, maar het object wordt niet gedeactiveerd bij het retourneren van de methode.

Van toepassing op