CmCspUpdateConnectionConfig (Compact 7)
3/12/2014
This function is called by the Connection Manager to update connection settings.
Syntax
CM_RESULT CmCspUpdateConnectionConfig(
__in_bcount(CM_CONNECTION_NAME_LENGTH) const WCHAR* szConnection,
__in_bcount(cbTypeSpecificInfoPrevious) const BYTE* pTypeSpecificInfoPrevious,
__in DWORD cbTypeSpecificInfoPrevious,
__in_bcount(cbTypeSpecificInfoNew) const BYTE* pTypeSpecificInfoNew,
__in DWORD cbTypeSpecificInfoNew,
__out BOOL* pfDisconnectToApplyChanges
);
Parameters
- [in] szConnection
The connection name
- [in] pTypeSpecificInfoPrevious
The previous configuration settings.
- [in] cbTypeSpecificInfoPrevious
The number of bytes in the pTypeSpecificInfoPrevious member.
- [in] pTypeSpecificInfoNew
The new configuration settings.
- [in] cbTypeSpecificInfoNew
The number of bytes in the pTypeSpecificInfoNew member.
[in,out] pfDisconnectToApplyChanges
[in] A pointer to a storage area to place the output.[out] Indicates if a disconnection was made during the update.
TRUE Disconnection occurred during the update.
FALSE No disconnection occurred during the update.
Return Value
The following table shows the possible return values.
Value | Description |
---|---|
CMRE_SUCCESS |
The call succeeded. |
CMRE_INVALID_CONNECTION |
The connection does not exist. |
CMRE_INVALID_PARAMETER |
One of the input parameters is invalid. |
CMRE_INCONSISTENT_CONFIGURATION |
The update would result in an invalid configuration, and has been rejected by the Connection Service Provider. |
CMRE_OUT_OF_MEMORY |
Memory can not be allocated to complete the operation. |
CMRE_UNEXPECTED |
An unexpected failure occurred. |
Remarks
This function is called by the Connection Manager and processed by the Connection Service Provider.
This function first determines the differences between the two configuration structures, pTypeSpecificInfoPrevious and pTypeSpecificInfoNew, and the configuration that is currently active.
If pTypeSpecificInfoPrevious is different from the configuration that is currently active, an error is returned.
If the supplied configuration structures are different, the differences are analyzed and applied to the configuration that is currently active.
Requirements
Header |
cmcsp.h |
See Also
Reference
Connection Service Provider Functions