Hot answers tagged

8

I'm assuming you provisioned the column as a site column. 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 ...


8

You could also use _api/Web/Lists/GetByTitle('List title')/DefaultDisplayFormUrl If you want for all lists do _api/Web/Lists?$select=DefaultDisplayFormUrl Note that the property is not visible when visiting List directly, need full path or $select.


5

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

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 ...


4

Use DefaultDisplayFormUrl at the time of loading the list in Javacript client object model. Example: var clientContext = new SP.ClientContext.get_current(); var list = clientContext.get_web().get_lists().getByTitle(listTitle); clientContext.load(list, 'DefaultDisplayFormUrl'); Then while enumerating the listitemcollection use get_defaultDisplayFormUrl() ...


3

You need to use the substring options available in XSLT to get what you want substring-before and substring-after. Like this: <xsl:value-of select="substring-before("&le;/a&gt;", substring-after("*&quot;&gt;", @Betrieb))"/> Not fully tested, the encodings might be off for the greater than, less than, and double quote characters. ...


3

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 ...


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 ...


3

You can parse the ID parameter from query string in Dispform.aspx, once you have the ID value you can update "Add new Item" link and pass ID from DispForm.aspx. Please refer to Parse Query String from Javascript to parse URL and get value from Query String.


2

Depending on your settings, the newform.aspx page will either open in a dialog (iframe) or open in a new page. Here is how I address this issue in my SPELL library: I don't pass the ID in the URL, but instead I run a script on newform.aspx that follows these steps: When the new form opens, check the parent window if the parent exist (dialog), then the ID ...


2

Sorry for replying with answer after long time. I wondered when I saw there is no answer to this question. So decided to do self-reply to this question. After lots of brain storming I get to know there was silly mistake I did in feature receiver. When I debug application I come to know that I was getting null values from site column properties. Then I placed ...


2

In SharePoint 2010, the default display forms include an anchortag in the table rows with a name attribute of: SPBookmark_YourFieldName If you are using those default display forms, you can take advantage of this and locate your values using jQuery like the following. In this example, my date field is named 'SiteCreateDate': // my example list field is ...


2

Using jQuery, find the nearest item with a unique identifier. Not all fields in a form have unique IDs, as you found with the date fields, which all have the id="SPFieldDateTime". The corresponding label column, however, contains the field name and this one must be unique. Use this as your hook. You can then go to the sibling of the unique element with ...


2

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 ...


2

Are you changing the Supporting Files for the list in the properties? Don't forget that you need to select the right Content Type (usually Item or Document).


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

select above should be: substring-before(substring-after(@Lookup, '&gt;'), '&lt;/a&gt;')


2

Using JavaScript you can change the URL query string Source and place the DisplayForm http://spjsblog.com/2011/04/23/redirect-from-newform-to-dispform-or-editform/#comment-195397


2

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"]; ...


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. ...


2

It is simple like this. SPUtility.GetSPField('City').Hide(); Please refer this question to show how to apply it. Edit: As far as you are concerned not only on the displaying and having high security concerns over the security of data, you better try something like creating another list with a one-to-one mapping. Then add a lookup column from first list ...


2

Yes, you can do this by SharePoint Designer. Add a lookup column to the Orders list, which will refer to the Customers list Open Customers list in SharePoint Designer Edit Customers Display Form, from the toolbar, select Insert a "Related Item View", your Orders list should show up in the option list, choose it Add/Remove columns of the Orders view You ...


2

Take the last backup and restore it to a new site collection. Make a granular backup from central admin on the calendar list. Restore the granular backup calendar to your lost calendar.


2

You want to override function PreSaveAction() instead of detecting the click with JQuery.


1

The name column actually has a different internal name. You can use LinkFilename to reference the name column.


1

To get the document name in your custom display form try this, it worked for me. <tr> <td width="190px" valign="top" class="ms-formlabel"> <H3 class="ms-standardheader"> <nobr>Name</nobr> </H3> </td> <td> <CustomTemplate> <SharePoint:FormField ControlMode="Display" ...


1

What did you put in your CCS class fontIncrease Do other (SharePoint) CSS Selectors have more CSS Specificity? You can make your CSS definitions more !important .fontIncrease{ font-size:1.5em !important; color:grey !important; } or stick a style="font-size:1.5em;color:grey" attribute on the field


1

Rather than editing the display form - try this: Create a view with all the fields that you need to show Set the view style to "Preview Pane" Result is very similar to your requirements i.e. when you hover on the item title the details are displayed in an area adjacent to that.


1

Why not inject some simple javascript in a custom displayform, make it as the default, and do a simple redirection on the default form? <script> var newUrl = window.location.toString().replace("DisplayForm", "EditForm"); window.location = newUrl; </script>



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