• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Macro / Function to get data from Web

skarnik01

Member
Hi,

I am looking out for a Macro / feature in Excel for the below -

I am trying to get data from Website - https://www1.nseindia.com/products/content/equities/indices/historical_index_data.htm
and put it in Excel.

I tried using Data >> From Web in Excel. However, it provides Yellow Arrow at Page level and does not allow me to select the table. Also the process is anyways quite manual in nature.

The page provides 3 parameters :
Select Index - which I intend to keep it equal to "Nifty 50"
Select Time Period (From & To) - will be for approx. last 50 entries, can be alternatively asked to the user, when he runs the Macro / function.

I now wish to import the data to the Excel file, for columns - Date, Open, High, Low, Close and Shares Traded for the selected dates.

Can anyone please help me on this? Macro will be the best solution, however, if any expert can help me pull the data through any other tool, that is still appreciated.

I tried through another alternative site - Yahoo Finance. Here it allows me to pull the data, however, the Accuracy levels are better in the NSE website.

Thanks in advance
 
I believe that Power Query provides this functionality - I'll go and look in my Data Monkey book and confirm this ....:cool:

What version of excel are @skarnik01 you using? Power Query is an add-in from 2010 onward, I think .... It's built in to the most recent Excel ...
 
I believe that Power Query provides this functionality - I'll go and look in my Data Monkey book and confirm this ....:cool:

What version of excel are @skarnik01 you using? Power Query is an add-in from 2010 onward, I think .... It's built in to the most recent Excel ...
Hi,

Thank you for your reply. I will look forward for your help.
I am using Excel 2010
 
When you use download option, just select open with Excel …

As here it's the Excel formulas forum and not the appropriate VBA one,
I can just advise you may also load data directly
with some Web Scraping methods upon an asp address
just grabbed using the webbrowser inner inspector tool,
for example with an http request, not very difficult,
maybe not for a beginner but just at medium / intermediate level …

Even just with the asp address you may use a QueryTable as usual
(Data, From Web) at beginner level !

And not forgot to do an usual web search (no matter the search engine)
because nse website is common on VBA forums …
 
Back
Top