Hot answers tagged

6

I came across this today and found another workaround. When the web part is added to the page it creates a hidden view on the list it is bound to. You can get the hidden view and make the changes to it directly. This works for announcements, calendars and doc libraries from what I have tested so far. Example: private static void AddWebPart(Web web, ...


5

Just manage to find the answer as follows: Select the list view web part and modify it and remove the 'Title URL' under the 'Advanced' section will do. Reference: http://intl.feedfury.com/content/16270498-how-to-remove-the-web-part-title-bar-link.html


4

In brief, just don't use XsltListWebPart on Application Pages. And here are some summarized explanations: XsltListViewWebPart and other OOTB SharePoint webparts (especially complex ones), apparently just aren't supposed to work in Application Pages environment. In other words, they weren't tested there and thus their operability is not guaranteed. This ...


4

I tested your code and I can confirm the behavior you described. There seems to be a bug where, no matter what XmlDefinition you specify, a webpart attached to a document library always ends up showing the default OOB view (Name, Modified, Modified By). If it were server object model, then it would be possible to cast the webpart to the underlying object ...


4

Thanks Robert! I am banging my head on the wall for this! Basically you don't have to add a code just to show the ribbon by default. Just go navigation and tick NO to show or hide command ribbons. According to the error that i got below, it is referencing to a script outside our domain. Webpage error details Message: Script error Line: 0 Char: 0 Code: ...


4

I suggest you check out SPServices. It's a "jQuery library which abstracts SharePoint's Web Services and makes them easier to use." http://spservices.codeplex.com/


4

Don't know really HOW, but this code works! Take a look =) public partial class VisualWebPart1UserControl : UserControl { private Microsoft.SharePoint.WebPartPages.ListViewWebPart myListView; protected override void CreateChildControls() { base.CreateChildControls(); SPSite oSiteCollection = SPContext.Current.Site; ...


4

According to the HTML of WebPart Title, your jQuery should not work. HTML of WebPart Title looks like. <span title="Project List" id="WebPartTitleWPQ3" class="js-webpart-titleCell"> <h2 style="text-align:justify;" class="ms-webpart-titleText"> <a accesskey="W" href="/Projects/Lists/Project%20List"> <nobr> ...


3

You can preview list item metadata on hover of list item. Like: Reference Links are Link1 Link2 Link3


3

Ok I resorted to a jQuery solution as I can get my head around it easier than anything SharePoint throws at me! As all lists have the class ms-summarycustombody I was able to get the following to convert the table to ul var div = $("<div id='viewport' class='viewport'></div>"); var list = $("<ul id='announcementList'></ul>"); var ...


3

The only out-of-box WebPart that supports audience filtering by content item is the Content Query Web Part. It is part of the Publishing Infrastructure Site Collection feature and requires SharePoint Server edition (not included with Foundation). Add a CQWP to your page, wire it up to your linked list, and then click the checkbox to enable Audience ...


3

Not with OOTB default webparts. You can convert these to data view webparts and utilize multiple connections.


3

You can do this by editing xslt in spd, namely you should change <xsl:value-of select> tag and add the surrounding <a> <a href="http://vxmc2170345/Lists/facilty/DispForm.aspx?ID={substring-after($thisNode/@IDofListX., '#')}"> <xsl:value-of select="substring-after($thisNode/@IDofListX. , '#')"/> </a> more detail: ...


2

Yes this is sharepoint OOTB error.. No solution for this If you want all users to have search enabled you can break permission and give them contribute permision at list level. Enable the show ribbon ->Always true


2

Since XsltListWebPart.ViewGuid and XsltListWebPart.XmlDefinition properties are ignored when adding web part via CSOM it makes it impossible to specify custom view for XsltListWebPart web part. Solution Since the default view is used when web part provisioned via CSOM, the proposed solution would be to modify default view during web part provisioning: ...


2

myListView.ViewGuid = list.DefaultView.ID.ToString("B").ToUpperInvariant(); did the trick for you... If you set the ViewGuid property, it needs the Guid of the particular View Case sensitive!


2

This works in VIEWS on SP2010,13,16 & Online, and does not require jQuery or any extra JavaScript files or (Content Editor) WebParts Disclaimer: you need minor JavaScript skills (just to understand what you are copy pasting), and debugging this code is PITA The Lookup info you are after is actually available in the Context object once the VIEW has ...


2

For targetting individual WebParts on one screen, and without jQuery document.querySelector(["#WebPartTitleWPQ2 nobr>span"]).innerHTML="New Title"


2

The difference between .dwp and .webpart The difference is .dwp was the file extension used in version 2 of SharePoint and .webpart is a new extension used in version 3. Inside the files, the schemas are different and it is indicated as such by the version number on the xmlns attribute.


2

Try this. The url will take you to the display form of the item. (function () { var overrideContext = {}; overrideContext.Templates = {}; overrideContext.Templates.Header = "<ul id='local-news2'>" overrideContext.Templates.Item = CBody; overrideContext.Templates.Footer = "</ul>" ...


2

fallout, I had the same problem and it was solved simply by using XsltListViewWebPart class instead ListViewWebPart. Hope that it helps,


1

I just had the same issue. Like Dribbel already wrote in his comment, if the Statement of Curtis Ruppe is correct: Microsoft specifically targets the Invalid, Event, and Survey list types to ignore client rendering. Unless you create your own webpart you will not ever be able to use any of the JSLink properties for these list types JSLink does not ...


1

This the best option. Other option is to create a new View and setting it to the web part.


1

did quite the same in my environment. You can take a look into my guideline I wrote here: https://afrait.com/blog/like-list-items-facebook-like-en


1

Well, I found this, which will prevent the List Tools from appearing when you click into the listview webpart! That's even better. $(".s4-wpcell").removeAttr('onkeyup').removeAttr('onmouseup');


1

Maybe this link from stack overflow site can help you to create multiple filter webpart OR You can passing two or more filter parameter by using query string web part. This link will give you tutorial how to use query string webpart to filter list item. You can use custom control to add query string to your site url. Hope it solve your problem.


1

I think you are using webpart connections. If so, You cannot do this. A webpart can only be connected to another webpart through one connection type and Each connection can have only one connection type. So, you cannot establish two connections between same instance of Provider and Consumer webpart. However, You can connect a provider web part with two ...


1

You can add several list filters through sharepoint designer but you cant do this through the front end web page


1

it sounds like you are using all oob webparts. In this situation - if I'm understanding it correctly - I would use jQuery to handle your presentation. If it's custom webparts then I would handling completely different (all in the webpart itself). So, I think your on the right track by using jQuery if I'm understanding the situation correctly.


1

Edit the webpart file to set the default value using the property tag <property name="" type="">[value]</property> It probably isn't working because once it is altered you can't set the default property again in that webpart.



Only top voted, non community-wiki answers of a minimum length are eligible