Following a great tip from How can I get rid of the columns header when the style 'Boxed' was selected?

I was able to hide all the column headers and everyone was happy! Until of course someone (that pays the bills) asked that for that one list, I bring back the headers. I added a bit of code in the webpart to reverse the effect. I used

 { display: none;}

replacing none by: block, inherit, contents, grid... everything I could think of. Some work but the headers are not aligned with the columns, they appear in the wrong place. I would appreciate some advice on this. Thanks

  • You could try .ms-viewheadertr { display: inherit !important;}. This should override any CSS that doesn't also have the !implortant instruction. – KGlasier Nov 2 '18 at 19:42
  • Thanks for the idea, that did not work. The columns are not on top of the data. It shows all the headers with nothing under them, then to the right of that all the data – Eric Dumas Nov 6 '18 at 17:35
  • Could you add a screen shot showing whats going wrong? – KGlasier Nov 6 '18 at 17:49
  • Hi, I added screenshots at drive.google.com/drive/folders/… – Eric Dumas Nov 14 '18 at 17:04

You can just do this:

 { display: "";}

It has worked for me every time.

| improve this answer | |

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.