Knowledge Walls
Gopal Rao
Mumbai, Maharashtra, India
Passcode:
Sp service example in Content query web part of MS Sharepoint server
1832 Views
Example:1
	
<script language="javascript" type="text/javascript" src="jquery-1.4.3.min.js"></script>
<script language="javascript" src="jquery.SPServices-0.7.0.min.js"></script>
<script type="text/javascript">
    $(document).ready(function () {
         $().SPServices({
            operation: "GetListItems",
            async: false,
            listName: "[LIST NAME]",
            CAMLViewFields: "<ViewFields><FieldRef Name=\"Status\" /><FieldRef Name=\"COLUMN NAME\" /><FieldRef Name=\"COLUMN NAME\" /></ViewFields>",
            completefunc: function (xData, Status) {
               $(xData.responseXML).SPFilterNode("z:row").each(function () {
                  var status = $(this).attr("ows_COLUMN NAME");
                  var createdDate = $(this).attr("ows_COLUMN NAME");
              });
          }
       });
});
</script>


Example: 2
	<script src="/Style%20Library/Scripts/jquery-1.6.2.min.js" type="text/javascript"></script>
	<script src="/Style%20Library/Scripts/jquery.SPServices-0.7.1a.min.js" type="text/javascript"></script>
	<script language="javascript" type="text/javascript">
	    $(document).ready(function () {
	        $().SPServices({
	            operation: "GetListItems",
	            async: false,
	            listName: "Test",
	            CAMLViewFields: "<ViewFields>  <FieldRef Name='Title' /> </ViewFields>",
	            completefunc: function (xData, Status) {
	                $(xData.responseXML).SPFilterNode("z:row").each(function () {
	                    alert($(this).attr("ows_Title"));
	
	                });
	            }
	        });
	    });
	</script>
Next Topics
Next lessons of current book.
Content query web part of MS Sharepoint server
Content query web part of MS Sharepoint server
Picture gallery web part of MS Sharepoint server
Best solution url of MS Sharepoint server
Best solution url of MS Sharepoint server
Previous Topics
Previous lessons of current book.
Content query web part of MS Sharepoint server
Content query web part of MS Sharepoint server
Best Lessons of "MS Sharepoint server"
Top lessons which are viewed more times.
Best solution url of MS Sharepoint server
Content query web part of MS Sharepoint server
Content query web part of MS Sharepoint server
Picture gallery web part of MS Sharepoint server
Content query web part of MS Sharepoint server
Best solution url of MS Sharepoint server
Content query web part of MS Sharepoint server
Content query web part of MS Sharepoint server
  Copyright © 2014 Knowledge walls, All rights reserved
KnowledgeWalls
keep your tutorials and learnings with KnowledgeWalls. Don't lose your learnings hereafter. Save and revise it whenever required.
Click here for more details