IMSCSPage_3_0::Encode

Ee783627.c++_off(en-US,CS.10).gifEe783627.vb_on(en-US,CS.10).gif

Use this method to apply HTML encoding to the specified text string.

This method is identical to the HTMLEncode method, which is the preferred name for this function. The Encode method applies HTML encoding to the specified text string. Characters in the string, such as "<" and "&" that have special meanings in HTML, are converted into their HTML equivalents, such as &lt; and &amp; so that they will be displayed correctly by the client browser.

Ee783627.important(en-US,CS.10).gif Important

  • This method is included for backwards compatibility with Site Server 3.0 Commerce Edition.

Definition

HRESULT IMSCSPage_3_0::Encode(VARIANTvtValue,BSTR*pbstrRet);

Parameters

vtValue

[in] A VARIANT that contains the text string to encode.

pbstrRet

[out, retval] A pointer to a BSTR used to return the encoded HTML text.

Return Values

This method returns an HRESULT indicating whether or not it completed successfully. See the Error Values section for more details.

Error Values

This method returns S_OK (0x00000000) to indicate success and standard COM HRESULT error values to indicate failure. For more information about standard COM errors, see Standard COM Errors. Additional information may be available using the global Err object, which can be accessed using the API function GetErrorInfo. In particular, the GetDescription method of the IErrorInfo interface may return a text description of the error.

Remarks

The pbstrRet parameter points to valid data only if the method completed successfully.

For more information about memory ownership issues related to COM property and method parameters, see Managing COM Parameter Memory.

See Also

Page Object

IMSCSPage_3_0::HTMLEncode


All rights reserved.