PowerTCP Mail for .NET
BeginUnsubscribe Method
See Also  Send comments on this topic.
Dart.PowerTCP.Mail Namespace > Mailbox Class : BeginUnsubscribe Method




state
User state information.
Begins to asynchronously unsubscribe the mailbox.

Syntax

Visual Basic (Declaration) 
Public Function BeginUnsubscribe( _
   ByVal state As Object _
) As IAsyncResult
Visual Basic (Usage)Copy Code
Dim instance As Mailbox
Dim state As Object
Dim value As IAsyncResult
 
value = instance.BeginUnsubscribe(state)
C# 
public IAsyncResult BeginUnsubscribe( 
   object state
)
Managed Extensions for C++ 
public: IAsyncResult* BeginUnsubscribe( 
   Object* state
) 
C++/CLI 
public:
IAsyncResult^ BeginUnsubscribe( 
   Object^ state
) 

Parameters

state
User state information.

Return Value

An IAsyncResult that represents the asynchronous operation, which could still be pending.

Exceptions

ExceptionDescription
Dart.PowerTCP.Mail.ProtocolExceptionBad IMAP protocol response received from server.
System.Net.Sockets.SocketExceptionThe requested address is not valid in its context.
System.InvalidOperationExceptionBeginXXX method used without providing an EndXXX event handler.

Remarks

The Mailbox.BeginUnsubscribe method begins to asynchronously unsubscribe the mailbox. Upon completion, the Imap.EndUnsubscribe event is raised. Use of this method causes the IMAP UNSUBSCRIBE command to be sent to the server to unsubscribe the mailbox.

To get a list of subscribed mailboxes use

Imap.List("", "%", false);

Requirements

Target Platforms: Microsoft .NET Framework 2.0

See Also

Documentation Version 3.2
© 2010 Dart Communications. All Rights Reserved.