_ShippingMethodManager::GetInstalledMethodList

Ee810659.c++_off(en-US,CS.10).gifEe810659.vb_on(en-US,CS.10).gif

Use this method to get a list of the current shipping methods. The GetInstalledMethodList method allows you to filter the list, select the columns to return, and to sort the list into a particular order.

Definition

HRESULT _ShippingMethodManager::GetInstalledMethodList(VARIANT*Filter,VARIANT*OrderBy,VARIANT*columns,VARIANT*rsReturn);

Parameters

Filter

[in] A pointer to a VARIANT that contains a BSTR that becomes the WHERE clause of the query. Pass a null variant if no filtering is wanted. An example filter is "enabled = 1", this will cause GetInstalledMethodList to only return enabled shipping methods.

OrderBy

[in] A pointer to a VARIANT that contains a BSTR that becomes the ORDER BY clause of the query. Pass a null variant if no ordering is wanted. An example OrderBy argument is "shipping_method_name", which will cause the results to be sorted by shipping_method_name.

columns

[in] A pointer to a VARIANT that contains a SAFEARRAY of column names of the values to retrieve. If an empty array is passed, all columns from the ShippingConfig table are returned.

rsReturn

[out, retval] A pointer to a VARIANT containing an ADO Recordset object with the wanted values.

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 rsResult parameter points to valid data only if the method completes successfully.

The GetInstalledMethodList method constructs a SQL query from its three parameters, runs it against the current ShippingConfig table, and returns the result in an ADO Recordset object.

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

See Also

Splitter

Shipping Object

ShippingDiscountAdjust

ShippingManagerCache

ShippingMethodManager Object

ShippingMethodRouter

StepwiseShipping


All rights reserved.