leeksleeks
Board Regular
- Joined
- Oct 31, 2013
- Messages
- 96
Hi,
I was wondering if anyone could help with this query. I have a worksheet that imports data from a website using a simple web query import. The thing is there are 3 different sections of the web address that I would like vba to replace each time based on text that is in Cells A2, B2 and D2.
For example:[TABLE="width: 500"]
<tbody>[TR]
[TD="align: center"]A2[/TD]
[TD="align: center"]B2[/TD]
[TD="align: center"]C2[/TD]
[TD="align: center"]D2[/TD]
[/TR]
</tbody>[/TABLE]
[TABLE="width: 500"]
<tbody>[TR]
[TD="align: center"]Apples[/TD]
[TD="align: center"]Bananas[/TD]
[TD="align: center"]Blank[/TD]
[TD="align: center"]Plums[/TD]
[/TR]
[TR]
[TD="align: center"]Grapes[/TD]
[TD="align: center"]Lemons[/TD]
[TD="align: center"]Blank[/TD]
[TD="align: center"]Oranges[/TD]
[/TR]
</tbody>[/TABLE]
The web query that it imports the data from is like the address below:
www.fruit.com/apples/bananas/plums
So what I would like the code to do is that once it has finished importing the data from the above web address, I would then like it to move onto the next query using Grapes/Lemons/Oranges which are in cells B2,C2,D2 and so on and so on.
I would like this to continue to loop through a worksheet called "Data" until there is no fruit left.
Is this possible? I thank you in advance. I dont have a fruit addiction fyi.......
Cheers!
I was wondering if anyone could help with this query. I have a worksheet that imports data from a website using a simple web query import. The thing is there are 3 different sections of the web address that I would like vba to replace each time based on text that is in Cells A2, B2 and D2.
For example:[TABLE="width: 500"]
<tbody>[TR]
[TD="align: center"]A2[/TD]
[TD="align: center"]B2[/TD]
[TD="align: center"]C2[/TD]
[TD="align: center"]D2[/TD]
[/TR]
</tbody>[/TABLE]
<tbody>[TR]
[TD="align: center"]Apples[/TD]
[TD="align: center"]Bananas[/TD]
[TD="align: center"]Blank[/TD]
[TD="align: center"]Plums[/TD]
[/TR]
[TR]
[TD="align: center"]Grapes[/TD]
[TD="align: center"]Lemons[/TD]
[TD="align: center"]Blank[/TD]
[TD="align: center"]Oranges[/TD]
[/TR]
</tbody>[/TABLE]
The web query that it imports the data from is like the address below:
www.fruit.com/apples/bananas/plums
So what I would like the code to do is that once it has finished importing the data from the above web address, I would then like it to move onto the next query using Grapes/Lemons/Oranges which are in cells B2,C2,D2 and so on and so on.
I would like this to continue to loop through a worksheet called "Data" until there is no fruit left.
Is this possible? I thank you in advance. I dont have a fruit addiction fyi.......
Cheers!