Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
MyFriendlyName
Collapse the table of content
Expand the table of content

IMessengerService::MyFriendlyName Property

[MyFriendlyName is no longer available in Windows Vista. See Windows Messenger for more information.]

Retrieves the local user's friendly name that corresponds to the selected service.

This property is read-only.

Syntax (get)

HRESULT get_MyFriendlyName(
  [out, retval]  BSTR *pbstrName
);

Parameters

pbstrName [out]

Pointer to a BSTR containing the friendly name for the local user of this service.

Return Value

Returns one of the following values.

Return codeDescription
S_OK

Success.

RPC_X_NULL_REF_POINTER

pbstrName is a NULL pointer.

E_FAIL

pbstrName returned a NULL string.

E_OUTOFMEMORY

String comparison failed.

MSGR_E_NOT_LOGGED_ON

This service is offline.

 

Remarks

The following table lists error codes returned by this method.

Error CodeMeaning
0x80004005pbstrName returned a NULL string.
0x8007000EString comparison failed.
MSGR_E_NOT_LOGGED_ONThe local user is not logged in to the selected service.

 

For a table of MSGR_E_* constants, see MSGRConstants.

Note  This property is not available for scripting languages.

Examples

The following Visual Basic example shows the use of this method.


Public WithEvents MsgrUIA As MessengerAPI.Messenger
Public MsgrServices As MessengerAPI.IMessengerServices

Private Sub btnServicesCount_Click()
    On Error Resume Next
    MsgBox("Services Count= " & CStr(MsgrServices.Count))
    ErrorTrap ("MsgrServices.Count")	'Error handling routine
End Sub

Requirements

Header

Msgrua.h

IDL

Msgrua.idl

DLL

Msgsc.dll

See Also

IMessengerService
MySigninName
MyStatus

 

 

Send comments about this topic to Microsoft

Build date: 6/30/2010

Community Additions

ADD
Show:
© 2015 Microsoft