title: function is not defined at HTMLButtonElement.onclick
body: <p>I want to call the function DeleteRow and EditRow on click of Delete Button and Edit Buttton.</p>
  
  <pre><code>&lt;button style="margin-right: 5px;" type='button' onclick='return EditRow(@i)' id='@editrow' class='btn btn-primary btn-sm pull-right'&gt;&lt;i class='glyphicon glyphicon-edit'&gt;&lt;/i&gt;  &lt;/button&gt;
  
  &lt;button style="margin-right:5px;" type='button' onclick='return DeleteRow(@i)' id='' class='btn btn-danger btn-sm pull-right'&gt;&lt;i class='fa fa-times-circle'&gt;&lt;/i&gt;  &lt;/button&gt;
  </code></pre>
  
  <p>I have also made functions on my JavaScript file but I am getting this "undefined Error function error". </p>
  
  <p>JavaScript Function here</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
  function DeleteRow(id) {
  debugger 
  //logic here
  return false;
  }
  
  function EditRow(id) {
  //logic here
  return false;
  }
  &lt;/script&gt;
  </code></pre>
  
  <p>I have got similar error before but at that time I only changed the function name in onClick at html and changed the function name at JavaScript but now no matters what I rename the function, I am getting the same error. </p>
  
  <p>Can anyone explain why I am getting this error</p>