Skip to main content


 

Symptoms


k2 app error after reset master was done in a site collection.
 

Diagnoses


We are getting an error after reset master page was done for all subsites in a site collection:

Accessing referenced file https://apps-abcdefghihijkl.denallixapps.com/teams/forms/_catalogs/masterpage/seattle.master from https://apps-abcdefghihijkl.denallixapps.com/teams/forms/abc/K2forSharePoint/Pages/Application.aspx?formUrl=/Runtime/Form/K2 for SharePoint?SPSiteURL=https://portal.denallix.com/teams/forms/abcandSPListId={GUID}andSource=https://denallix.com/teams/forms/abc/Lists/ListName/AllItems.aspx is not allowed because the reference is outside of the App Web.
 

Resolution

Out-of-the-box, the K2 for Sharepoint app will use the default "app.master" page. When the the reset master page was performed, it is likely that the "Reset all subsites to inherit this site master page setting" was checked similarly to one of the causes in the blog below:

http://mctalex.blogspot.com.au/2013/07/powershell-fix-for-app-master-problem.html

Which caused the K2 for Sharepoint app to now reference the "seattle.master" page in which the K2 app is not able to access. I believe you will need to use the "Better Resolution" Sharepoint powershell as per blog:

http://blogs.catapultsystems.com/eskaggs/archive/2015/02/12/sharepoint-2013-accessing-referenced-file-from-is-not-allowed-because-the-reference-is-outside-of-the-app-web/

to update the custommasterurl and masterurl for the K2 for Sharepoint App web. You will most likely need to run this powershell whenever a K2 for Sharepoint App is added/updated before attempting to run the Registration Wizard or after a master page reset. The "Better Solution" powershell script should reset any "AppWeb" including the K2 for Sharepoint app web to using the default "app.master" page.

One thing that you can do is edit the "if" statement in that powershell to:

if($_.IsAppWeb -eq $true){
write-host($_.CustomMasterUrl)
write-host($_.MasterUrl)
}

This will now list of of the app web in your site collection to help you confirm if the appweb are "K2 for Sharepoint" appwebs. If there are non-K2 appweb, perhaps the powershell can be edited to target only the K2 appwebs.




 
Be the first to reply!

Reply