PeerNearMe::AddToContactManager Method (String^, String^, MailAddress^)

 

Generates a PeerContact with the associated descriptive parameters from the PeerNearMe object and associates it with the ContactManager.

Namespace:   System.Net.PeerToPeer.Collaboration
Assembly:  System.Net (in System.Net.dll)

public:
PeerContact^ AddToContactManager(
	String^ displayName,
	String^ nickname,
	MailAddress^ emailAddress
)

Parameters

displayName
Type: System::String^

The display name assigned to the newly created contact.

nickname
Type: System::String^

The nickname to assign to the newly created contact.

emailAddress
Type: System.Net.Mail::MailAddress^

MailAddress object that specifies the email address to assign to the newly created contact.

Return Value

Type: System.Net.PeerToPeer.Collaboration::PeerContact^

PeerContact object associated with a PeerNearMe containing descriptive parameters.

Exception Condition
PeerToPeerException

The Collaboration infrastructure has failed to create or update a PeerContact with the ContactManager.

.NET Framework
Available since 3.5
Return to top
Show: