Sharepoint 2010 Customize Chart Webpart Title
-
Thursday, May 24, 2012 5:58 PM
Hello,
I want to customize the web part title to display list item name from a custom list. Is it possible to write javascript code or to use sharepoint designer? Can any one help me with this. Thank you.
- Edited by Sharepoint Developer-Administrator Thursday, May 24, 2012 8:47 PM
All Replies
-
Thursday, May 24, 2012 11:42 PM
Yes, you can do this with Javascript using the SPServices and jQuery libraries. You can use SPServices to read the list item name from a custom list. If you have a single web part on the page(s), you can use jQuery selectors to find the first <span> tag after an object with a class of ms-WPTitle and replace its text with the list item text.
If you have multiple web parts, you will need to work a little harder to change the one(s) you want, but it should be possible.
-
Thursday, May 24, 2012 11:49 PMAny sample code or links Andy, Thanks for your time.
haritha.
-
Wednesday, May 30, 2012 11:59 AMModerator
Hi haritha,
Please check following links to retrieve list items using JavaScript.
http://msdn.microsoft.com/en-us/library/hh185007.aspx
http://ranaictiu-technicalblog.blogspot.com/2010/07/sharepoint-2010-use-ecmascript-to.htmlThen use IE F12 Developer Tools to get right HTML tags and overwrite it similar like the step in this blog.
http://techtrainingnotes.blogspot.com/2010/08/sharepoint-2010-change-add-new-item-and.html
Thanks & Regards,
EmirEmir Liu
TechNet Community Support
- Marked As Answer by Emir LiuMicrosoft Contingent Staff, Moderator Friday, June 01, 2012 2:35 AM
-
Tuesday, June 12, 2012 9:21 PMThanks I got the solution using Jquery and SPServices....
haritha.

