0
在Excel vba中,我試圖導航一個URL並從指定的URL獲取表數據。錯誤「HTTP 403網站拒絕顯示此網頁」在Excel vba中導航URL
首先,我硬編碼的URL
Set ie = CreateObject("InternetExplorer.Application")
ie.navigate "https://www.nseindia.com/live_market/dynaContent/live_watch/get_quote/GetQuoteFO.jsp?underlying=VGUARD&instrument=OPTSTK&strike=195.00&type=CE&expiry=29JUN2017"
這工作得很好,我在Excel中得到了表數據。
現在我想採取基本和罷工(見鏈接)從我的工作表中2個獨立的組合框(ComboBox1和ComboBox2)。
因此,我改變URL作爲
ie.navigate "https://www.nseindia.com/live_market/dynaContent/live_watch/get_quote/GetQuoteFO.jsp?underlying=" & ComboBox1.Value & "instrument=OPTSTK&strike=" & ComboBox2.Value & ".00" & "&type=CE&expiry=29JUN2017"
但它給我一個 錯誤 ::: HTTP 403網站拒絕顯示此網頁
我該如何解決?
https://en.wikipedia.org/wiki/HTTP_403 –