IDebugProcessSecurity::GetUserName

Note

This article applies to Visual Studio 2015. If you're looking for the latest Visual Studio documentation, see Visual Studio documentation. We recommend upgrading to the latest version of Visual Studio. Download it here

Gets the user name from the port supplier.

Syntax

HRESULT GetUserName(  
    BSTR *pbstrUserName  
);  
int GetUserName (  
    string pbstrUserName  
);  

Parameters

pbstrUserName
[out] A string containing the user name.

Return Value

If the method succeeds, it returns S_OK. Otherwise it returns an error code.

Remarks

GetUserName returns the user name that is displayed in the User Name column of the Attach to Process dialog box. To view the Attach to Process dialog box, click Attach to Process on the Tools menu in the Visual Studio integrated development environment (IDE).

See Also

IDebugProcessSecurity