ferocious12
Member
Hi All,
I am working on a code to copy product title for all the products appearing on amazon search page and paste it to column A. I have the following code. Need help to click on each product found on the amazon page and copy the product title and paste it in column A:
Images and code below. Appreciate the help !
I am working on a code to copy product title for all the products appearing on amazon search page and paste it to column A. I have the following code. Need help to click on each product found on the amazon page and copy the product title and paste it in column A:
Images and code below. Appreciate the help !
Code:
Sub Ama_Prod()
Dim IE As New InternetExplorer, elem As Object
Dim Html As HTMLDocument, imgs As Object
With IE
.Visible = False
.navigate "https://www.amazon.in/s?k=sarees&ref=nb_sb_noss_2"
While .Busy Or .readyState < 4: DoEvents: Wend
Set Html = .document
End With
' 1. click on each product title on page html as follows
' <span class="a-size-base-plus a-color-base a-text-normal">women's art silk kalamkari and bhagalpuri style saree with blouse piece and soft feel (kora)</span>
' 2. copy the id "product title" from each individual page to column A. HTML for 1st product as follows"
' <h1 id="title" class="a-size-large a-spacing-none"> <span id="productTitle" class="a-size-large"> Yashika women 's art silk kalamkari and bhagalpuri style saree with blouse piece and soft feel (kora)</span>
' </h1>
End Sub
Last edited: