NDdeGetTrustedShare function

[Network DDE is no longer supported. Nddeapi.dll is present on Windows Vista, but all function calls return NDDE_NOT_IMPLEMENTED.]

Retrieves the options associated with a DDE share that is in the server user's list of trusted shares.

Syntax

UINT NDdeGetTrustedShare(
  _In_  LPTSTR  lpszServer,
  _In_  LPTSTR  lpszShareName,
  _Out_ LPDWORD lpdwTrustOptions,
  _Out_ LPDWORD lpdwShareModId0,
  _Out_ LPDWORD lpdwShareModId1
);

Parameters

lpszServer [in]

The name of the server on which the DSDM resides.

lpszShareName [in]

The share name whose trusted status is being queried. This parameter cannot be NULL.

lpdwTrustOptions [out]

A pointer to a variable that receives the trust options. This parameter cannot be NULL. The following trust options are available.

Value Meaning
NDDE_CMD_SHOW_MASK
0x0000FFFFL
Mask used to obtain the value used to override the DDE share show state, if NDDE_TRUST_CMD_SHOW is set.
NDDE_TRUST_CMD_SHOW
0x10000000L
Override the show state specified in the DDE share DSDM.
NDDE_TRUST_SHARE_DEL
0x20000000L
Remove the share's trusted status.
NDDE_TRUST_SHARE_INIT
0x40000000L
Allow a client to initiate to the application if it is already running in the user's context.
NDDE_TRUST_SHARE_START
0x80000000L
Allow the application to be started in the user's context.

lpdwShareModId0 [out]

A pointer to a variable that receives the first part of the trusted share modify identifier. This parameter cannot be NULL.

lpdwShareModId1 [out]

A pointer to a variable that receives the second part of the trusted share modify identifier. This parameter cannot be NULL.

Return value

If the function succeeds, the return value is NDDE_NO_ERROR.

If the function fails, the return value is an error code, which can be translated into a text error message by calling NDdeGetErrorString.

Remarks

The trusted share modify identifier reflects the version of the DDE share in the DSDM at the time the DDE share was initially granted trusted status. The trusted share modify identifier is primarily used to remove obsolete trusted shares. However, the user does not need to remove obsolete trusted shares. The network DDE agent removes obsolete shares on the user's behalf.

Requirements

Requirement Value
Minimum supported client
Windows 2000 Professional [desktop apps only]
Minimum supported server
Windows 2000 Server [desktop apps only]
Header
Nddeapi.h
Library
Nddeapi.lib
DLL
Nddeapi.dll
Unicode and ANSI names
NDdeGetTrustedShareW (Unicode) and NDdeGetTrustedShareA (ANSI)

See also

Network Dynamic Data Exchange Overview

Network DDE Functions

NDdeSetTrustedShare