Tag Info

New answers tagged

1

I don't think you can prevent the redirect as you have little control over the layouts page's behavior. Here's a workaround you can try: Use the Source parameter and force the NewDocSet.aspx page to redirect to an intermediate page, a page that you've written, and execute your code there. function Opendialog() { var options = ...


2

As Long as you just include the newDocSetPage in a Modaldialog, you won´t get a DialogResult.cancel, just because the newDocSet.aspx doesn´t know about your modaldialog and therefore won´t Close it using SP.UI.DialogResult.OK. You will have to do this by yourself. Either there is is possible using the JavaScript-Client object model, or you will have to ...


0

I tried with the answer mentioned by Daniel but was unable to get the result. I have been able to get a file with a particular name from the document set by the following approach: Fetch all the items of the Document library Check whether the item is a document or not If it document set, check whether it has subfolders When is does not have sub folders, ...


0

This should work var query = new SPQuery(); query.RowLimit = 1; query.Folder = documentSet.Folder; query.Query = string.Format("<Where><Eq><FieldRef Name='ContentType' /><Value Type='Computed'>{0}</Value></Eq></Where>", "ContentTypeName"); var items = documentSet.ParentList.GetItems(query);


4

this worked for me. var ctx = SP.ClientContext.get_current(); var list = ctx.get_web().get_lists().getByTitle('Calendar'); var item = list.getItemById(121); item.resetRoleInheritance(); ctx.executeQueryAsync(function(){alert('success')},function(s,a){alert(a.get_message())}); if you are opening the OOTB EditForm from a link on your custom CEWP, execute ...



Top 50 recent answers are included