Solved

How to implement merchantcalculationurl in google checkout in my asp.net application?

Posted on 2012-03-19
2
380 Views
Last Modified: 2012-08-14
I send the shopping cart request to Googr le checkout sing the following code, in the code behind of the Google checkout button. What is the next step after this? HOw do I read the response for this request. I also need to get the shipping information. HOw do I redirect. Please help. thanks

Dim request As CheckoutShoppingCartRequest = New CheckoutShoppingCartRequest("merchantid", "key", EnvironmentType.Sandbox, "USD", 120)
        request.AddItem("ITem 1", "desc 1", 2.0, 1)
        request.AddStateTaxRule("CT", 0.06, True)
        request.AddStateTaxRule("MD", 0.05, False)
        Dim cart As Byte() = request.GetXml()
        cart = request.GetXml()

        Dim res As GCheckoutResponse = request.Send()
        Response.Redirect(res.RedirectUrl, True)
0
Comment
Question by:TrialUser
2 Comments
 
LVL 42

Accepted Solution

by:
sedgwick earned 500 total points
ID: 37741183
follow this tutorial:
http://code.google.com/apis/checkout/samples/Google_Checkout_Sample_Code_NET.html

it describes exactly what to do and how.
0
 

Author Comment

by:TrialUser
ID: 37744741
The document does not explain the Merchantcalculations api and notification  API. I want to know how to write these pages. Thanks

This section is from the document. I want toknow how to implement these.
Merchant Calculations API -

Create an .aspx page that will handle merchant-calculation-callback requests from Google Checkout. This page should parse merchant-calculation-callback requests and then call the methods that you use to calculate taxes, shipping charges, and discounts for coupons and gift certificates.

The classes and methods in the MerchantCalculations directory of the sample code distribution may help you to develop the .aspx page. Please check this document in coming weeks for more detailed instructions about how to call and use these methods.

Use the URL for your .aspx page as the value of the <merchant-calculations-url> element in your Google Checkout API requests. Google Checkout will then send merchant-calculation-callback requests to your .aspx page.

Notification API -

Create an .aspx page that will handle notifications, such as order state change notifications, and then send the information in those notifications to the appropriate internal systems.

Note: The .NET sample code distribution does not include classes or methods to process notifications or to send notification acknowledgments.

Enter the URL for your .aspx page in the API callback URL field in your Google Checkout settings. To locate this field, log in to your checkout account and click the Settings tab. Then click the Integration link in the menu on the left side of the page.
0

Featured Post

Does Powershell have you tied up in knots?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Parsing a CSV file is a task that we are confronted with regularly, and although there are a vast number of means to do this, as a newbie, the field can be confusing and the tools can seem complex. A simple solution to parsing a customized CSV fi…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question