Tag Info

Hot answers tagged

3

To create a form that would submit items to multiple lists, you should: Add some elements to your main list form, probably arranging them in a certain way. If those elements aren't related to fields as I suspect from your description, best way to do it would be to leverage OnPostRender CSR event and then use HTML5 selectors or jQuery to insert your HTML ...


3

in your page make sure there is no reference to core.css.... issue is due to masterpage which has that reference that the page your using could be referencing the masterpage. several methods: 1) if its referencing a masterpage than make a custom masterpage that is almost the same only that it doesnt contain the core.css reference. 2) within your css add ...


3

Here is the C# version of Anders answer as it was not as straightforward as I would have thought. public static void SetFormJSLink(this SPList list, PAGETYPE formBaseView, string jsLinkUrl) { var file = list.ParentWeb.GetFile(list.Forms[formBaseView].Url); file.CheckOut(); using (var manager = ...


2

I am not sure i can understand correctly your question, but it seems to me that you want to submit a form via "original" save button. But would like to do your own code in between. If that's correct, what I usually do is to return 'false' in PreSaveItem. Then do all the things I need to do and then submit form with javascript like this: function ...


2

I can think of 2 possible ways to achieve this: Create a separate Web Part with your form only, and add that web part in the same page as the XsltListViewWebPart. Create a custom Web Part in Visual Studio that has both the form AND the XsltListViewWebPart. You can override the CreateChildControls (and other methods) to have both components coexisting in ...


2

I usually do an <xsl:value-of select="substring-after(@YourField, ';#')" /> I believe. You might need to adjust the ;# part but as I recall, the lookup field value is returned like 1;#Name. So in you example (had to edit your post to see it) it would be like: <div id="Artikelnaam"><xsl:value-of select="substring-after(@Artikelen, ';#')" ...


2

I'm actually fairly sure this isn't possible -- and the reason might seem kind of silly, but is a limitation of the architecture having to deal with content types: Forms (edit/view) are associated with a particular content type; so when you go to a list and edit an item, the first question SharePoint asks before it renders any form is 'what content type is ...


2

That's one of the UI issues in SharePoint 2013, that when Enhanced Rich Text is selected the required validation message appears twice. I don't know if there is an update available to fix this (and other issues). But you can try some JS/jQuery to hide one of them.


2

This is known issue with custom forms. Can you try replacing "<SharePoint:FormField" with <SharePoint:ClientPeoplePicker runat="server" ID="MyControlName" Required="true" ValidationEnabled="true" InitialHelpText="text" VisibleSuggestions="3" Rows="1" AllowMultipleEntities="true" CssClass="ms-long ms-spellcheck-true" /> you can also try the ...


2

Please consider using Virto Form Extender (http://www.virtosoftware.com/products/content-mgmt/virto-ajax-list-form-extender). It is stated that fields visibility can be dynamic on new/edit list item form.


2

SharePoint 2013 is using Client Side Rendering by default, so form controls are rendered on client side on some other internal javascript events. It is possible that jQuery.ready() handler is firing too early while controls are not rendered yet and that could be main problem. My suggestion would be not to use jQuery.ready, where normal jsLink with CSR ...


1

Just create new forms in Designer and delete what you don't want displayed. Be sure they aren't required fields that aren't answered yet, or you'll get errors, but it's super simple.


1

Open the edit form page in browser and then add a Script Editor Webpart. Edit the Snippet and use below script <script type="text/javascript"> $(document).ready(function(){ var textToAppend = "<b>Text to Insert</b><br/>"; var temp = $('select[Title="Content Type"]').parent().html(); ...


1

Create field on list 1 to store value -> Create a workflow so when you create item on List 1, it creates item on list 2. Then waits 1 minute, then updates List 1 with ID from List 2. This way the pause will allow the ID to be generated before attempting to update it. This works if you don't need immediate access to the ID link and can wait 1 minute for it to ...


1

Simplest way will be to create a view which shows only those items in which Created By= [Me] or Team Member =[Me] filter. This view will shows only those items which are created by current logged in user or if the training is assigned to that user. So other managers will not see other training which they have not created. Make this view as the default view. ...


1

Yes, this is possible. You can add Last three field in section (Containers). After adding fields in section, add rules to this section to display only when login user is inside a SharePoint user group. You can add data connection having SharePoint user group there. And validate the same using rule applied in section. The blog ...


1

I found a Solution for this case. While using the attributes UseDefaultListFormWebPart="FALSE" or UseLegacyForm="TRUE" did not add the default form webpart, SharePoint threw an UnsafeControlException. It looks like the DataFormWebpart on my NewVisitor.aspx could not be used "standalone" this way. The final solution was following: Open ...


1

I was able to use a custom form in place of the default one, without duplicated fields by applying the attribute UseLegacyForm="TRUE" on my custom form registration. In your case that should become: <Forms> <Form UseLegacyForm="TRUE" Type="DisplayForm" Url="DisplayVisitor.aspx" ...


1

From InfoPath Designer Select File menu tab Select SharePoint List template Select Design Form button Enter Site URL Select existing List Select Content Type The new InfoPath Form is now associated with a specific Content Type. https://kerdirks.wordpress.com/2012/10/03/associate-custom-infopath-form-with-list-content-type/


1

You can create standard html form with javascript. You can do with it what you want and write on list using Java Script Object Model on button click or something with javascript. With this approach you can do with the form what you want. On button click you can write item on list and don't close the form, so you can reuse data putting next item on a list. ...


1

The good thing with using ASP.NET is you can write your own logic and customize it whenever needed with much flexibility. It is relatively difficult than using InfoPath as we have to be concerned about the page life-cycle a lot. Also you can manage it easily with asp:view controllers when a large amount of components are there. (In your case 300) But on the ...


1

I am not involve in IP form designing but i know one of our department create IP form with tons of fields which slow down their site collection. Personally, As we know, this is last version of IP so i think better to design in ASP.net or access form. Check this post, they discuss couple of limitation. Disadvantages of implementing InfoPath in SharePoint ...


1

In addition to customizing List Views & Forms via XSLT, with SharePoint 2013 was introduced a Client Side Rendering (CSR) technique. As an introductory please follow this article Introduction to Client Side Rendering in SharePoint 2013. Since CSR is the default rendering mode in SharePoint 2013, I would recommend this approach to customize a New Form ...


1

On the NewForm.aspx add a Script Editor Web Part (from Media and Content) and add the following script: <script type="text/javascript"> window.location.replace(http://theListUrl/MyCustomNewForm.aspx); </script> But be careful. If you do, the only option to get it back to where it "normal" is to edit the NewForm.aspx in SharePoint Designer: ...


1

When I want to change the style of one of the default forms I use something like this. The key is creating a new html form, and giving each element you want to include a span tag with the name "hillbillyform". Then the script will look for these fields, and apply the styles that you choose. This is applied using a CEWP on the form you desire to modify. ...


1

70 fields on one form does not sound like a great user experience. You may want to re-think your data architecture. Other discussions show that exceeding the limit will result in a stack overflow error. Even a field that is just displayed would need to be on the stack, so the display mode will probably not help much. In any case, why don't your try it ...


1

Try this: to disable the textarea $("textarea[title^='What']").attr('disabled', 'disabled'); to hide $("textarea[title^='What']").css('display', 'none !important'); or $("textarea[title^='What']").parent().find("iframe").hide(); $("textarea[title^='What']").css('display', 'block !important'); $("textarea[title^='What']").attr('disabled', ...


1

You don't need to use any code to hide your fields in every form.. Just create a new Content Type with the fields you need, attach it to the list (ensure that its the 1st CT / remove the default CT) and that's the metadata that will show up in your NewForm Make sure you inherit your Content Type from the parent 'Event'


1

I would use Knockout JS to bind your inputs and jQuery to submit/create SPList items. here is an example of knockout dynamic row binding: http://knockoutjs.com/examples/gridEditor.html Personally i try to stay away from SPServices and rather use OOB JavaScript api's. Infopath is almost dead, i wouldn't invest my time creating forms etc with it.


1

I had this problem because one of my coworkers had tried to customize the master page in SharePoint Designer. The master was already customized, with code, through Visual Studio, so the existence of a detached copy made SharePoint throw a fit since code isn't allowed on pages inside the content database. To fix it, I located the offending master page in ...



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