Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 306
  • Last Modified:

If I integrate the google checkout into my asp.net application, how can I access the shippin g and billing information entered by the user in google checkout

I am trying to integrate google checkout into my ecommerce website. In my ecommerce website, I maintain a record of the shipping and billing address. If the user choosesgoogle checkout, is this information available to the merchant through some Google API? My application is ASP.net / vb.net application

Thanks
0
TrialUser
Asked:
TrialUser
1 Solution
 
TrialUserAuthor Commented:
I have created a sandbox account and I send my shopping cart to google check out.
Next step I need to check if the authorization was valid and create a transaction in my db and process the order.

How do I check the response from Google after sending the shoppng cart. Should I create a webservice for this or is this done in a webpage inside my application. please help.
this is the code I have so far:
 Protected Sub GCheckoutButton1_Click(ByVal sender As Object, ByVal e As System.Web.UI.ImageClickEventArgs) Handles GCheckoutButton1.Click

        Dim dtShoppingCart As DataTable
        Dim strUserName As String = Web.HttpContext.Current.User.Identity.Name
        If strUserName = String.Empty Then
            strUserName = request.AnonymousID
            dtShoppingCart = csShoppingCartBO.GetCart(strUserName, False)
        Else
            dtShoppingCart = csShoppingCartBO.GetCart(strUserName, True)
        End If

        Dim reqShoppingCart As CheckoutShoppingCartRequest = New CheckoutShoppingCartRequest("merchantid", "key", EnvironmentType.Sandbox, "USD", 120)
        If dtShoppingCart.Rows.Count >= 1 Then
            For intItems As Integer = 0 To dtShoppingCart.Rows.Count - 1
                reqShoppingCart.AddItem(dtShoppingCart.Rows(intItems)("SKU"), dtShoppingCart.Rows(intItems)("ShortDescription"), dtShoppingCart.Rows(intItems)("Quantity"), 1)
            Next
        End If

        Dim cart As Byte() = reqShoppingCart.GetXml()
        cart = reqShoppingCart.GetXml()

        Dim res As GCheckoutResponse = reqShoppingCart.Send()
        Response.Redirect(res.RedirectUrl, True)
    End Sub
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now