Tag Info

Hot answers tagged

6

I believe that the EditForm.aspx you are referring to (Workflow > Open task list > Forms > EditForm.aspx) is for the standard tasks in the task list. Workflow tasks, though they are in the same list, operate a little differently. Firstly, what type of workflow is it? Browser SharePoint Designer Visual studio Workflow tasks created by the approval ...


6

This is the way it works for me: <tr> <td valign="top" class="ms-formlabel"><nobr>Created by</nobr></td> <td valign="top" class="ms-formbody"> <SharePoint:CreatedModifiedInfo ControlMode="Display" runat="server"> <CustomTemplate> <SharePoint:FormField FieldName="Author" ...


6

An easier to implement option than an event receiver is a Workflow, triggered by the first list, to insert data from that entry into another list. This can be easily built using SharePoint Designer.


6

The below code access current user's department and manager from AD: SPSite _site = SPContext.Current.Site; ServerContext serverContext = ServerContext.GetContext(_site); UserProfileManager myUserProfile = new UserProfileManager(serverContext); UserProfile currentUserProfile = myUserProfile ...


6

You can do this by using the SPUtility.js library As example I have created a simple list with: Title (simple text). Country (ChoiceField) [Tunisia, Switzerland, Canada, France, Other] – Other is the default value. City (Simple text). By default the City field is hidden if the Country field value is Other. Every list has three default forms to add, ...


4

Have you considered email enabled libraries? Since 90% of your users do not have access, you should consider that to get the information or form into SharePoint. If you use InfoPath, you could possibly still do this with an email distributed form, then the completed form would be an attachment and could be emailed into the library.


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

One way at least is to use this CSS: .ms-formtoolbar { display: none; }


3

You should not have to worry about how the dialog launches, it should happen seamlessly from the ribbon new button no matter the content type. I would check two things: Is the site operating with v4 (sp2010) visual styles? Is the list configured to show forms in a dialog. List Settings -> Advanced -> Dialogs -> Launch forms in a dialog? -> Yes The list ...


3

Okay, so after some debugging I found the problem and, even better, the solution. The OK button on the attach form runs a script called OKAttach(), which features a line towards the end that reads: document.getElementById("idAttachmentsRow").style.display=""; All well and good, except that at some point SharePoint sneaked behind your back and did this to ...


3

For 2010: Add this to the page in a content editor webpart, or add to the page layout <script language="javascript" type="text/javascript"> function DoAction() { var clientContext = new SP.ClientContext.get_current(); var web = clientContext.get_web(); var user = web.get_currentUser(); clientContext.load(user); ...


3

You can use jQuery to find the fields and apply css to them with something like: $("h3[class^='ms-standardheader']:contains('Assigned To')").css("font-weight", "Bold"); $("h3[class^='ms-standardheader']:contains('Description')").css("font-weight", "Bold");


3

You're probably looking for InputFormControl. It should be placed inside Template_Control tag of InputFormSection control. In header section of your custom user control, you will need to add the following code: <%@ Register TagPrefix="wssuc" TagName="InputFormSection" Src="~/_controltemplates/InputFormSection.ascx" %> <%@ Register ...


3

Robert... This time, dont use relative URLs, just add absolute URL (the entrie path of the page) eg. <input type="button" value="Add List Item" name="BtnSave" onlick="javascript: {ddwrt:GenFireServerEvent('__commit;__redirect{http://<server>/sites/<site name>/Pages/<page name>.aspx}')}" /> It should work, cheers


3

The best practice approach is to make copies of each of the forms then edit the copies. Then on the custom forms you can add in custom list form web parts and style and change until your heart's content. With SharePoint 2010, you can also utilize InfoPath to customize the forms pretty easily. Here (from MSDN) is a nice excercise on that process.


3

This looks like good place to start: Custom SharePoint List Forms It will give you some insight on what can be done. Replacing default forms with custom application pages is briefly explained at bottom of the article. I am very fond of this technique but I never come across some really good article that explains everything.


3

Can't resist mentioning, that the "Open" button on the ribbon and the link on the folder title are still there, and they really do the same what you want, with only one click cost. Anyway, certainly there are several approaches to achieve what you want. Approach 1: iframe I believe the most simple way would be what I call "dirty js hack"... It is NOT ...


3

If you have followed the steps correctly, it should work. Make sure that, once you have created the application page, the solution explorer structure looks like this - Deploying this will create the folder and files for you inside the "Layouts" folder.


3

A couple of issues: The Id part of SPFieldLookupValue should be the Id of the listitem in the list with groups (Groups?) not the Id of the item you're updating. So ideally you setup the ddlGroups with Text=Text from Groups and Value=Id of corresponding listitem in Groups. The code to populate the ddlGroups should be changed to: foreach (SPListItem ...


3

Another way to do it (if "Open with Explorer" works for you) In the form library, on the ribbon navigate under "Library Tools" to the "Library" tab. In the "Connect & Export" section find "Open with Explorer". Depending on your screen resolution the full label may not be displayed; the icon looks like a folder with an arrow pointing to a computer ...


3

Create custom edit form using SPD so that DataFormWebPart is generated: Go to this form and edit it. Find the following code: <SharePoint:SaveButton runat="server" ControlMode="Edit" id="savebutton1"/> Replace it with the following code: <input type="button" value="Save" onclick="javascript: ...


3

It seems that for JSLink to work on the display/new/edit forms you need to set the JSLink on the webpart used in the forms, not directly on the form itself. The following PowerShell code works for the new form on a blog post and should be easy to adopt to your needs in C#: $web = Get-SPWeb "http://myportal" $file = $web.GetFile("Lists/Posts/NewPost.aspx") ...


3

Yes, there is. In the list go to List Settings > Form Settings and tick "Use the default SharePoint Form". If you keep the option "Delete the InfoPath form from the server" unticked, you can later switch back to the IP form. If you tick that option, it will be gone for good.


3

In SharePoint PreSaveItem function is called when onClick event handler is fired for Save button in List Forms. PreSaveItem function: function PreSaveItem() { if ("function"==typeof(PreSaveAction)) { return PreSaveAction(); } return true; } PreSaveAction function from another hand, allows to override behavior for a Save button. It ...


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

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


2

This is a bit tricky. You can edit the View page for a task pretty easily (that is the first one that comes up when you click on a task list). When you open it, you see some generic labels and text boxes. The page is actually built from an enumeration at run time. You can use the Insert ribbon at the top to drop your own Data View Web Part under the generic ...


2

This article describes doing it "the advanced way" in Visual Studio, which gives most control: http://www.codeproject.com/Articles/195348/SharePoint-2010-State-Machine-Workflows-with-Custo It is not 100% intuitive, but right elements are there.



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