Function

$().SPServices.SPSPGetDisplayFromStatic

Functionality

This function returns the DisplayName for a column based on the StaticName. This simple utility function, which utilizes the GetList operation of the Lists Web Service, seemed useful to expose as a public function.

Prerequisites

None

Syntax

$().SPServices.SPSPGetDisplayFromStatic ({	
	webURL: "",			// URL of the target Web.  If not specified, the current Web is used.
	listName: "",			// The name or GUID of the list
	columnStaticName: ""			// StaticName of the column
the current user is used.
});

Example

The following example will return the DisplayName for the Title column in the States list in the current site.

<script language="javascript" type="text/javascript" src="../../jQuery%20Libraries/jquery-1.3.2.js"></script>
<script language="javascript" type="text/javascript" src="../../jQuery%20Libraries/jquery.SPServices-0.4.0.js"></script>
<script language="javascript" type="text/javascript">
	$(document).ready(function() {
		$().SPServices.SPSPGetDisplayFromStatic ({	
			listName: "States",
			columnStaticName: "Title"
		});
	});
</script>
Last edited Oct 22 at 5:22 AM by sympmarc, version 2
Comments
No comments yet.

Updating...
© 2006-2009 Microsoft | About CodePlex | Privacy Statement | Terms of Use | Code of Conduct | Advertise With Us | Version 2009.10.27.15987