Differences with SharePoint View Styles
I was putting together a sampling of views to demonstrate the various view styles in SharePoint and came across a bit of a bug (well, an annoyance really). First just a quick rundown of the various styles you can apply in a view:
View Style is the style you set by selecting it from a list when you create or edit a view. There are 7 styles to choose from, all with different twists to how they present your list or document library. The nice thing is you can get some variations on presenting things to the user without having to resort to a DVWP. Okay, I'll admit there's not a lot of styles out-of-the-box nor are they fabulous in any way. A little variety but definately not a replacement for a custom FrontPage job.
So, without further adieu, here they are:
Basic Table
The Basic Table is pretty
much like the Default style. See below for details on what's
different but pretty much it renders your view in the
typical SharePoint view. Columns with clickable (sortable)
headers, etc.
Document Details
The Document Details
style is probably the most adventurous of the bunch and
renders your items 2 across (no matter how wide the page is)
with each item in a box. A link to the item itself and
whatever columns you enable for the view along with an icon
for the item and an icon for editing it.
Newsletter
I couldn't quite figure out
the Newsletter style at first but the only difference I
found from the Basic Table or Default style is that regular
text fields were bold. I still don't know why they called it
Newsletter?
Newsetter, no lines
Same as the
Newsletter style but guess what, the lines between each row
have been removed. Otherwise identical.
Shaded
Shaded is like the Default
style but every other row is shaded using the colour of the
site, alternating between dark and light. Typical ledger
type display and helps break up the monotony when you have a
lot of items.
Custom
The Custom style is set when
you change any of the other styles like doing grouping,
totaling or even adding columns. I guess it's there to just
indicate that it's not stock.
Default
The default is well, the
default. When you create a new document library or list you
get a view called All Documents (or All Items for lists).
This view uses the default style.
Now when you actually build a view and apply the Basic Table style you'll notice something. It looks exactly the same. Well it is, almost. The two are the same (ignoring the Guids for the views when compared side-by-side) however the Default style throws two copies of this snippet of code in:
<SCRIPT LANGUAGE="VBSCRIPT">
On Error
Resume Next
Set NewDocumentButton =
CreateObject("SharePoint.OpenDocuments.2")
If
(IsObject(NewDocumentButton)) Then
fNewDoc2
= true
Else
Set NewDocumentButton
= CreateObject("SharePoint.OpenDocuments.1")
End
If
fNewDoc = IsObject(NewDocumentButton)
</SCRIPT>
This VBScript is for rendering the correct button on a toolbar. The Default style puts the code in twice but the Basic Table only puts it in once. No biggie and it's not needed so I would classify it as a bug, but maybe I'm just difficult that way.
Anyways, hope that explains some things about the views and what the differences (and similarities) are.