1

I am getting this error uncaught typeerror cannot read property 'spservices' of undefined when I opened the editform,aspx from my SP 2010 list form. I got this error when I examined the F12-Dev Tools console of my Chrome browser.jQuery doesn't trigger even after I mention the files references correctly.What am I doing wrong?

     <SharePoint:UIVersionedContent UIVersion="4" runat="server">
    <ContentTemplate>
    </div>
    </ContentTemplate>
      </SharePoint:UIVersionedContent>
         <script language="javascript"
        src="/project/EOVHYSZ1/EASAssetsLib/jquery-1.6.0.min.js" 
       type="text/javascript"></script>
       <script language="javascript" 
      src="/project/EOVHYSZ1/EASAssetsLib/prototype.js" 
     type="text/javascript"></script>
        <script language="javascript" 
          src="/project/EOVHYSZ1/EASAssetsLib/SPUtility.js" 
      type="text/javascript"></script>
      <script language="javascript" 
       src="/project/EOVHYSZ1/EASAssetsLib/jquery.SPServices-
      2014.01.min.js" type="text/javascript"></script>
     <script type="text/javascript" language="javascript">
      var queryStringVals = $().SPServices.SPGetQueryString();
      //  var CSGANCHORNames= $().SPServices.SPGetCurrentUser();
             // alert(CSGANCHORNames);

      // We can pass in a section name on the Query String to expand by 
         default
        var expandSection = queryStringVals.section;
          $(document).ready(function() {
               alert('inside doc ready');  //this did not fire
          // Set up each of the sections -
            // see the setupSection function below for an explanation of 
       //the parameters
  • 1
    1.6.0 is very old jQuery version... sure both SPU and SPS can work with that? – Danny '365CSI' Engelman Oct 28 '15 at 14:25
  • It worked correctly for my newform.aspx and was able to get those field values in a very easy way, like sputilities.getfield('current status').getvalue(); in my presaveaction function call. Its weird that its not working for editform.aspx ! – userAZLogicApps Oct 28 '15 at 14:31
  • 2
    Check all depencies in F12.. does jQuery work, does Prototype work, does SPUtility work. If you want these libraries available it might be easier to load them in the MasterPage. – Danny '365CSI' Engelman Oct 28 '15 at 14:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.