Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

enter image description hereHi i am new to XSLT coding in share point, but i know that we can use XSLT coding to create a list view with more sty-lings. I have a list named "detailsOfEmployee" with columns title,name,id,salary,company. I want to create a view with columns name,company,salary with a condition that salary is greater than zero. Now i am using share point 2010 to create webpages. Can anyone please provide an example of xslt code for creating a list view or any link of a website which has a example with clear explanation.

share|improve this question
    
You should always start from the code that SPDesigner generates, then customize it –  MdMazzotti Apr 17 at 13:29
    
Is that we have create a list view using content editor then have start editing it in share point designer ??? –  vinod kumar Apr 17 at 13:32
    
I'm not sure I completely understood. Did you nest a ListView webpart within a content editor web part? Why didn't you add the LVWP directly in a webpart zone? –  MdMazzotti Apr 17 at 14:10
    
We can add LVWP as you told. But i want to customize my list view through XSLT, that is my requirement. –  vinod kumar Apr 21 at 5:59

1 Answer 1

Edit the page in Advanced edit mode, then in Split mode, click on the XSLTListViewWebPart tag. The List View Tools tab will open. Click on Design > Customize XSLT > Customize Entire View. At this point, the default XSLT code will be shown and you can start editing.

enter image description here

share|improve this answer
    
When i try to open my aspx page in share point 2010 designer it is not allowing me and it is asking choose some options like edit in browser, edit page layout. How can i edit my aspx page in share point ? –  vinod kumar Apr 22 at 10:52
    
@vinodkumar It means the page you're on is a publishing page. You can try detaching it from page layout, making your modifications, then re-attaching it –  MdMazzotti Apr 22 at 11:10
    
List View Tools tab is not visible in sharepoint 2010 even though after clicking on XSLTListViewWebPart tag. I have added a screen shot in my question. –  vinod kumar Apr 23 at 4:50

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.