Hot answers tagged display-form
4
If you want to customize a list new\edit\display form there is a couple of ways you can do it. I mean programming ways (not InfoPath). All this methods related to creating custom rendering templates. Every list form has its own rendering template, for list its a "ListForm", for document library "DocumentLibraryForm". All this templates (and otheres) listed ...
4
I am assuming you provisioned the column as a site column. So, the next thing is to make sure to push the changes to the down to lists and content types where this site column has been referred (which apparently you haven't done it). So, I would recommend to delete the old definition and provision the column again! See an example below where I am using the ...
3
You can use jQuery to change the behavior. This is based off something I did 2007, but the same should hold true in 2010. It appends a target=blank attribute to any a href that ends in .msi. You'd just need to change the selector to the proper attribute for the lookup field.
<script type="text/javascript" src="/Resources/jquery.js"></script>
...
3
You could edit the DispForm of the list item and in it have a delegatecontrol (or some other custom control) to count how many times the page has been loaded by unique user id's other than the authors id.
Update
Create a new user/web/delegate control and insert the following code:
var web = SPContext.Current.Site.OpenWeb();
var list = web.Lists["Name of ...
2
[There was a not useful answer]
UPDATE:
OK, I understand the problem now. In my case the field is present in the section (I've removed other fields for simplicity):
<DataFields>@MultiLookupTest_x003a_TestField,MultiLookupTest:TestField;</DataFields>
And then you can render it just in the same manner as others but you need to use a part of ...
2
Trying to change the display name of the Title is going to be an uphill struggle: There are several versions of the same column, each with their own DisplayName (some of which are created in the list).
If you open your list in SharePoint Manager, you'll see the various hidden Title fields.
My advice would be to hide the title field (Hidden="TRUE" in the ...
2
You have misunderstanding of using CustomActionGroup. It uses for creating groups not in ribbon, but in sharepoint pages, for example in site settings. Chris O'Brien has written good blog posts about ribbon customization here. And if you have doubts how to create ribbon button or group, it is good idea to digg into cmdui.xml (this file contains definition ...
2
The code you posted should work also for old lists, as it uses the Update(true) method. There is only one case I can think of, when pushing down changes from the parent Content Type to the child Content Type does not work: when the content type is either read-only, or sealed. Please read this site for more info.
Please let me know if that helped you.
...
1
As you already discovered, one way is to use the DelegateControl approach (with PlaceholderAdditionalPagehead) and that's in fact what I've been using for a couple of years now.
The key is how to access the built-in editform.aspx/dispform.aspx pages with the embedded WebPart showing the SPListItem. That's done by hooking your WebControl into ...
1
Create a base class for your web parts that handles exceptions. That way the page doesn't fail, just your web part. The error message is displayed on the page where your web part should be, the surrounding web parts are rendered normally. I use this as the base class for all my web parts.
...
1
I think you might be missing the fact that you need to update the CT after you have updated the field, also I normally don't declare the C as var but rather a CT.
See the code below:
(Also make sure the internal name "C" is unique to that field and not mixed with a required field in another CT.)
Best of luck
SPContentType ct = web.ContentTypes["CT"];
...
1
I normally hate "Why" answers, but here goes: WHY? The Edit Form is for modifying the properties of a list item, or a library item (document). The Display Form is for showing (read-only) the properties of a list/library item. If a user is looking at the item properties in read mode, they can click the link and get the document. If the user is in edit mode, ...
1
Why don't you add a Content editor web part on dispform.aspx and try adding the video play (code) there instead?
You can always add a Web Part to the list forms.
1
You can create as many DispForms as you'd like for a list. In SharePoint Designer, copy the existing Dispform and rename the copy. Hide the default form on the page by setting the IsVisible and IsIncluded flags to false. Then add in a Custom List Form web part. Customize as desired based on your requirements.
Then through navigational control and or ...
1
The parent SPMobilePage has a Response property which can be used to directly inject markup into the response stream.
So in this case in my OnLoad() method is simply find the parent and then add the processing instruction markup:
protected override void OnLoad(EventArgs e)
{
base.OnLoad(e);
SPMobilePage parent = this.Parent.Parent as ...
1
The preferred approach to implementing this would be to use a custom Rendering Template.
Rendering Templates are ASCX files in the ControlTemplates folder which define how SharePoint forms are displayed in both display and edit. There are high level templates 'form' and very low level templates like 'textbox'.
For multi lookup fields there is the template ...
Only top voted, non community-wiki answers of a minimum length are eligible