Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


These support forums are now closed for new topics and comments.
Please head on over to http://eureka.ucommerce.net/ for support.

  • Joshua Ryder 4 posts 34 karma points
    Jan 04, 2012 @ 13:09
    Joshua Ryder
    0

    Problem with DIBS / Payment

    Iam abit stuck with my payment. When i call  "Ucommerce.Xslt.Library.RequestPayments()" i just get:

     

    Server Error in '/' Application.

    HttpRequest does not contain at least 2 subdirections in the URL
    Parameter name: request

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.ArgumentException: HttpRequest does not contain at least 2 subdirections in the URL
    Parameter name: request

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    Stack Trace:

    [ArgumentException: HttpRequest does not contain at least 2 subdirections in the URL
    Parameter name: request]
       UCommerce.Transactions.Payments.PaymentUrlInformation.ExtractInformation(HttpRequest request) +313
       UCommerce.Transactions.Payments.UrlPaymentExtractor.Extract(HttpRequest httpRequest) +49
       UCommerce.Transactions.Payments.PaymentRequestForm.Execute(HttpContext context, IPaymentWindow& paymentWindow, Payment& payment) +116
       UCommerce.Transactions.Payments.PaymentRequestForm.ProcessRequest(HttpContext context) +193
       System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +100
       System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +75
    

     

     

      and page location: http://localhost:51651/6/PaymentRequest.axd

    iam running the newest version of uCommerce.

  • Søren Spelling Lund 1797 posts 2786 karma points
    Jan 09, 2012 @ 11:28
    Søren Spelling Lund
    100

    Turns out this is an issue with manually created payments if they are not assigned a payment guid (for security reasons).

    You can either do a payment["paymentGuid"] = Guid.NewGuid().ToString() or using UCommerce.Xslt.Library.CreatePayment to create the payment or invoke the payment factory with:

    var paymentMethod = PaymentMethod.All().Single(x => x.Name == "PayPal");
    var paymentFactory = paymentMethod.GetPaymentMethodService() as IPaymentFactory;
    Payment payment = paymentFactory.CreatePayment(paymentRequest); 
  • Joshua Ryder 4 posts 34 karma points
    Jan 12, 2012 @ 15:24
    Joshua Ryder
    0

    Thank you :) that worked perfect.

Please Sign in or register to post replies

Write your reply to:

Draft