IBackgroundCopyJob::GetDisplayName method

Retrieves the display name for the job. Typically, you use the display name to identify the job in a user interface.

Syntax


HRESULT GetDisplayName(
  [out]  LPWSTR *ppDisplayName
);

Parameters

ppDisplayName [out]

Null-terminated string that contains the display name that identifies the job. More than one job can have the same display name. Call the CoTaskMemFree function to free ppDisplayName when done.

Return value

This method returns the following HRESULT values, as well as others.

Return codeDescription
S_OK

Display name was successfully retrieved.

E_INVALIDARG

The ppDisplayName parameter cannot be NULL.

 

Examples

The following example shows how to retrieve the display name property value from the job. The example assumes the IBackgroundCopyJob interface pointer points to a valid job.


HRESULT hr;
IBackgroundCopyJob* pJob;
WCHAR* pszJobName = NULL;

hr = pJob->GetDisplayName(&pszJobName);
if (SUCCEEDED(hr))
{
  //Do something with pszJobName.

  CoTaskMemFree(pszJobName);
}

Requirements

Minimum supported client

Windows XP

Minimum supported server

Windows Server 2003

Header

Bits.h

IDL

Bits.idl

Library

Bits.lib

DLL

QmgrPrxy.dll

IID

IID_IBackgroundCopyJob is defined as 37668D37-507E-4160-9316-26306D150B12

See also

IBackgroundCopyJob::SetDisplayName

 

 

Community Additions

ADD
Show:
© 2014 Microsoft