A majority of the pipeline components included with Commerce Server 3.0 implement IPipelineComponentAdmin to support setting component properties using a configuration Dictionary. Consequently, for examples of how to build ASP-based property pages for components that implement this interface, you can refer to the ASP source for any of the Commerce Server for examples of how to build the edit and post pages for your component.
If your component exposes its properties by implementing Automation properties, you can use the template.asp and template_post.asp files as examples of how to create your property pages. These files are included in the \Microsoft Site Server\SiteServer\Admin\Commerce\Pipeline Configuration directory.
The following is the text of the template.asp file.
<%@ LANGUAGE = VBScript %>
<% REM############################################################ %>
<% REM %>
<% REM TEMPLATE.ASP %>
<% REM Microsoft Commerce Server v3.00 %>
<% REM Commerce Order Pipeline Editor %>
<% REM %>
<% REM Copyright (c) 1996-98 Microsoft Corporation. All rights <%reserved. %>
<% REM %>
<% REM ############################################### %>
<!--#INCLUDE FILE="pe_3rd_party_edit_header.asp" -->
field: <INPUT TYPE="TEXT" NAME="field" SIZE="70" VALUE="<%= ComponentConfig.field %>">
<!--#INCLUDE FILE="pe_3rd_party_edit_footer.asp" -->
The ComponentConfig object referenced on this page represents an instance of the component being configured, and field represents the name of the component’s dispatched property. For example, the MinMaxShip component dispatches the MinShipping and Percentage properties. To configure this component, the text above might be changed as follows:
field: <INPUT TYPE="TEXT" NAME="MinShipping" SIZE="70" VALUE="<%= ComponentConfig.MinShipping %>">
field: <INPUT TYPE="TEXT" NAME="Percentage" SIZE="70" VALUE="<%= ComponentConfig.Percentage %>">
The template_post.asp simply retrieves the values of the form fields submitted from the template.asp, and assigns the components dispatched properties the appropriate values.
<%@ LANGUAGE = VBScript %>
<% REM ################################################################# %>
<% REM %>
<% REM TEMPLATE_POST.ASP
<% REM Microsoft Commerce Server v3.00 %>
<% REM Commerce Order Pipeline Editor %>
<% REM %>
<% REM Copyright (c) 1996-98 Microsoft Corporation. All %>
<% REM rights reserved.
<% REM ############################################################## %>
<!--#INCLUDE FILE="pe_3rd_party_post_header.asp" -->
<%
field = mscsPage.RequestString("field", null, 1, 255)
if IsNull(field) then
errorList.Add "field must be a string between 1 and 255 characters in length"
else
ComponentConfig.field = field
end if
%>
<!--#INCLUDE FILE="pe_3rd_party_post_footer.asp" -->