Tag Info

New answers tagged

0

I copied below code from blog http://blog.vgrem.com/2014/01/20/working-with-discussions-list-via-sharepoint-client-object-model/ Create Discussion function createDiscussion(listTitle,properties,OnItemAdded,OnItemError) { var context = new SP.ClientContext.get_current(); var web = context.get_web(); var list = ...


0

So if I understand correctly, you want the discussion board available anonymously, but users would have to login/register to add or answer a question? In that case you would turn on anonymous access for the site collection and give anonymous users read permissions to the forums. Then whenever a user accessed something that requires permissions (such as ...


0

Pholpar, Thanks for the result. But i was working on an easier task. Finally did it. What i actually did : As soon as we have 6 replies to a Discussion Item we change the permission to read only for everyone.(and drop a mail) Solution: In the workflow Choose a "if" condition (Simple if not the current item one) DataSource : Select the Discussion list ...


0

Since a reply in Discussion Board is represented as List Item you could utilize a common update operation as demonstrated below: var ctx = SP.ClientContext.get_current(); var list = ctx.get_web().get_lists().getByTitle('Discussion Board'); var messageItem = list.getItemById(listItemId); //get message item by its Id messageItem.set_item('Body','Welcome to ...


0

How to post a reply in Discussion Board using SharePoint JSOM Use SP.Utilities.Utility.createNewDiscussionReply(Context, parent) Method to post a reply to a discussion item: function createMessage(discussionItem,properties,OnItemAdded,OnItemError) { var context = new SP.ClientContext.get_current(); var messageItem = ...


0

The easiest way is to create and register an ItemAdding event receiver that counts the replies of the user and cancel the save if the limit is exceeded. Alternatively, you can create your own ListFieldIterator and validate limit in the save event handler (see OnSaveHandler). See more details here, sample code is here . If you have SP 2013 (and not SP 2010 or ...



Top 50 recent answers are included