1

When using a ListView WebPart on a custom list and enable grouping for a view, the name of the group is always displayed as the first entry List view screenshot

I tried to find a way to get rid of the “Category:” label and found some different hints in the internet, but none really worked.

-> no entry with “xsl:value-of select="$fieldtitle” found in Designer

-> in my Custom View named “GroupedView.aspx” there was no “GroupByField” value (even search in notepad after copying the whole xslt from the designer found nothing)

The only thing that worked was a JS script I found on the blogspot from Amit Phule from 2011

Is there really no other way then using an client side script to remove those entries afterwards?

EDIT: Sorry Guys, as my first Screenshot was quite unhelpful, I modified the list a bit.

I want to get rid of the groupname "Category" over every Group.

Grouped listview with "groupname : value"

  • Not to be that guy, but having Categories named "Category 1" and so on, instead of just "1" seems quite redundant – Robert Lindgren Sep 12 '13 at 13:50
  • Even further, if you are grouping by category, why is it even a column in the display? It's not necessary. – Eric Alexander Sep 12 '13 at 21:13
  • Sorry, I just made some Screenshots of a new List, because I didn't want to bother you with entries from a german list ;) My Category name are "Objekt-Info", "Fachpresse",... But still the name of the Categoryfield is added to the display. – Leviani Sep 13 '13 at 7:49
  • Seems like the JS solution is the only way, sad but true. – Leviani Nov 11 '13 at 9:06
  • Open the page in sp designer and change the text colour to white. Vwala its gone :) – user30234 Jul 3 '14 at 10:27
0

Not quite sure you have resolved your problem. Yesterday I was looking for a solution as you asked. But for now, my problem is resolved by using jQuery.

Here is the result of my screen short:

enter image description here

I don't have any server client permission. My solution is write jQuery in CEWP.

Here is the code which i made:

enter image description here

Please note: 'Stage' is the field name which we need to replace. 'M1' and 'Start' is the name which we want to present. in the screen short, the line of "var i=0" should be "var i=1"

We're looking for long answers that provide some explanation and context. Don't just give a one-line answer; explain why your answer is right, ideally with citations. Answers that don't include explanations may be removed.

  • Can you please add more details about what code you used and how? – Robert Lindgren Mar 17 '15 at 8:34
  • Interesting idea, but I don`t want to replace the headers, I wanted to delete them. Another Issue with your idea is, that I have to modify the script each time a new category is added. Until now I used the JS snippet from Amit Phule linked in my question and it works as expected. The reason I posted the question above is, that I can't believe that there is no OOB way to do this :( – Leviani Mar 18 '15 at 8:33
  • your are right, my idea is not too much flexible. but it's resolved my problem currently:) I going to take a test of Amit Phule solution. – user3201159 Mar 18 '15 at 9:05

Your Answer

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

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