Microsoft KB Archive/300840

From BetaArchive Wiki

Article ID: 300840

Article Last Modified on 10/31/2003



APPLIES TO

  • Microsoft Commerce Server 2002 Standard Edition
  • Microsoft Commerce Server 2000 Service Pack 1



This article was previously published under Q300840

SYMPTOMS

When the SupplierAD Solution Site is customized, an invalid credit card can cause the following error:

Error Type:
  Microsoft VBScript runtime (0x800A01FB)
  An exception occurred: 'mscsOrderGrp.RunPipe'
  /include/std_pipeline_lib.asp, line 121

Browser Type:
  Mozilla/4.0 (compatible; MSIE 5.5; Windows NT 4.0) 
  Page:
    POST /crdtcard.asp 
  POST Data:
    verify_with_total=44.33&mode=2&btnSubmit=Place+Order 
Time:
  Monday, April 02, 2001, 6:10:57 PM 

  Active Server Pages error 'ASP 0115' 
  Unexpected error

  /crdtcard.asp 
  A trappable error (C0000005) occurred in an external object. The script
cannot continue running.
                    

CAUSE

Visual Basic cannot find the DispID after the error occurs.

RESOLUTION

Commerce Server 2000

To resolve this problem, obtain the latest service pack for Microsoft Commerce Server 2000. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

297216 INFO: How to Obtain the Latest Commerce Server 2000 Service Pack


WORKAROUND

To work around this problem, change the processing in Crdtcard.asp. If you find that the credit card is invalid during the POST, you can redirect back to the Crdtcard.asp page as follows:

        iErrorLevel = ValidateSubmittedCreditCardData(mscsOrderGrp,
listFlds, dictFldVals, dictFldErrs, listFrmErrs, sVerifyWithTotal)
        If iErrorLevel = 0 Then
            ' Validation of submitted data succeeded.
            bSuccess = True
        Else
            'This will prevent the AV in basket.pcf
            'Response.Redirect(GenerateURL(MSCSSitePages.CreditCard,
Array("verify_with_total"), Array(sVerifyWithTotal))+"?Error=1")
        End If
                

The URL is appended with "?Error=1". This value is read by the Request object in the Main function as follows:

Dim CreditCardError

Sub Main()
    Dim bSuccess
    Dim listMethods, listFrmErrs
    Dim dictFldVals, dictFldErrs
    Dim sVerifyWithTotal
    Dim urlAction
    Dim iOrderGroupID, iErrorLevel
    
    CreditCardError = Request("Error")
                

This initializes the CreditCardError global variable that is declared before Main. When the page is rendered by htmRenderCreditCardPage, the variable is checked and the error message is appended as follows:

    If CreditCardError Then
     htmContent = htmContent & "ERROR : " & RenderText(mscsMessageManager.GetMessage("pur_badcc", sLanguage),
MSCSSiteStyle.Error) & BR
    End If
                

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.


Additional query words: plutonium

Keywords: kbbug kbfix kbcommserv2000sp2fix KB300840