'This is the code to connect to Amazon's web service. You need to register with Amazon so you can get your 'own TokenKey to gain access. The user types in a subject for a book and this for goes to Amazon and finds the 'top 10 books from their database and puts the results into a datagrid Public Class WebForm1 Inherits System.Web.UI.Page Protected WithEvents txtKeyword As System.Web.UI.WebControls.TextBox Protected WithEvents txtMode As System.Web.UI.WebControls.TextBox Protected WithEvents lblKeywordSearch As System.Web.UI.WebControls.Label Protected WithEvents lblKeyword As System.Web.UI.WebControls.Label Protected WithEvents lblMode As System.Web.UI.WebControls.Label Protected WithEvents Search As System.Web.UI.WebControls.Button Protected WithEvents Label1 As System.Web.UI.WebControls.Label Protected WithEvents Label2 As System.Web.UI.WebControls.Label Protected WithEvents Datagrid1 As System.Web.UI.WebControls.DataGrid Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load 'Put user code to initialize the page here End Sub Private Sub Search_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Search.Click ' Variable to Store the Token Key Dim TokenKey As String ' Declare variable for the amazon search service object Dim Service As New Amazon.AmazonSearchService 'Declare variable for KeywordRequest which is the object 'for the search request Dim keyword As New Amazon.KeywordRequest ' Declare variable for the amazon Search Result Dim ProductInformation As Amazon.ProductInfo ' Please Type your token key here TokenKey = "14QT8CH5R794MHS1DT02" 'Fill in the properties of the keyword request keyword.keyword = txtKeyword.Text 'what you are searching keyword.mode = "books" 'txtMode.Text 'amazon product line keyword.page = 1 'page you want keyword.tag = "webservices-20" 'affiliate tag keyword.type = "lite" 'lite or heavy type keyword.devtag = TokenKey 'token key Try 'Initiate the search ProductInformation = Service.KeywordSearchRequest(keyword) 'Transform productInformation to DataSet Datagrid1.DataSource = TransformToDataSet(ProductInformation) Datagrid1.DataBind() Catch Response.Redirect("errorform.aspx") End Try End Sub 'Transforms ProductInfo to DataSet Function TransformToDataSet(ByVal productInfo As Amazon.ProductInfo) As DataSet 'Create the instance of dataset Dim ds As DataSet = New DataSet 'Create the headers ds.Tables.Add("ListedProducts") ds.Tables(0).Columns.Add("Image") ds.Tables(0).Columns.Add("ProductName") ds.Tables(0).Columns.Add("Authors") ds.Tables(0).Columns.Add("Price") 'Get the Details object collection from 'productInfo object Dim detailsCollection() As Amazon.Details = productInfo.Details 'Declare variables to be used in iteration Dim details As Amazon.Details Dim datarow As DataRow 'Iterate through detail object and 'get its properties For Each details In detailsCollection datarow = ds.Tables("ListedProducts").NewRow datarow("Image") = details.ImageUrlSmall.ToString() datarow("ProductName") = details.ProductName.ToString() datarow("Authors") = details.Authors(0).ToString() datarow("Price") = details.ListPrice.ToString() ds.Tables("ListedProducts").Rows.Add(datarow) Next Return ds End Function End Class