title: Script to store HTML Table into excel worksheet automatically every day at a specific time
body: <p>There is this website having a table which I want to save everyday at 18:00 Hrs. into a excel sheet named with the date and time.</p>
  
  <p>I have no idea of programming. I tried digging through Google and Stackoverflow and was able to figure out how to do it manually but I want this to be done everyday.
  Here I will list out the procedure that I have figured out using the internet and I want to automate the same.</p>
  
  <p>I go to this <a href="http://nseindia.com/live_market/dynaContent/live_watch/option_chain/optionKeys.jsp?symbolCode=-10003&amp;symbol=NIFTY&amp;symbol=NIFTY&amp;instrument=-&amp;date=-&amp;segmentLink=17&amp;symbolCount=2&amp;segmentLink=17" rel="nofollow">webpage</a> and click on inspect element and obtain the html code of the table (search for "octable").
  After getting the HTML code of the table, I run this javascript online using JSFiddle to get the excel file. </p>
  
  <p><div class="snippet" data-lang="js" data-hide="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>$(document).ready(function() {
      $("#btnExport").click(function(e) {
          //getting values of current time for generating the file name
          var dt = new Date();
          var day = dt.getDate();
          var month = dt.getMonth() + 1;
          var year = dt.getFullYear();
          var hour = dt.getHours();
          var mins = dt.getMinutes();
          var postfix = day + "." + month + "." + year + "_" + hour + "." + mins;
          //creating a temporary HTML link element (they support setting file names)
          var a = document.createElement('a');
          //getting data from our div that contains the HTML table
          var data_type = 'data:application/vnd.ms-excel';
          var table_div = document.getElementById('dvData');
          var table_html = table_div.outerHTML.replace(/ /g, '%20');
          a.href = data_type + ', ' + table_html;
          //setting the file name
          a.download = 'exported_table_' + postfix + '.xls';
          //triggering the function
          a.click();
          //just in case, prevent default behaviour
          e.preventDefault();
      });
  });</code></pre>
  </div>
  </div>
  </p>
  
  <p>I want to do all this steps automatically at 18:00 hrs every weekday. Can someone please help me here? If possible, can the same script be run over a remote server and the files are saved in cloud like google drive or emailed to my account?</p>
  
  <p>P.S.: Since I'm new here I don't have enough reputations to add images to the question :(</p>