UISearchController and Modifying it’s UITableView after Search

My beautiful dark table background had become styled back to a white background when working with the UISearchController and typing a word to filter. Lovely, I thought. It looks like it creates a new tableview for the filtering and isn’t smart enough to carry over styles. Why not just look at Apple’s documentation to see if I can find a way to reference the table view of filtered content with...

June 29, 2016 | No Comments

PowerShell and Project Euler 24: Lexicographic Permutations

Continuing from the last Project Euler post I worked on the lexicographic permutations quiz in PowerShell. The problem being: A permutation is an ordered arrangement of objects. For example, 3124 is one possible permutation of the digits 1, 2, 3 and 4. If all of the permutations are listed numerically or alphabetically, we call it lexicographic order. The lexicographic permutations of 0, 1 and 2 are: 012 021 102 120...

Managed Property in SharePoint That Returns the Full File URL

A Quick Tip Looking to find the URL directly to a file in a library and NOT the view form, or online document editor? Take a look at your out of the box managed property DefaultEncodingURL. This managed property will contain the absolute URL. However this property appears to be intended for Video links. If you plan on implementing the direct file URL I would suggest playing it safe and...

SharePoint Online: JSOM Examples

Introduction When working with the SharePoint API via Javascript it is essential to work with the Javascript Object Model (JSOM). JSOM is the use of JavaScript with the SharePoint client side API which allows you to work with SharePoint without deploying code to the server itself. Due to SP Online relying on sand-boxed approaches, JSOM (or CSOM) is typically what would be used for code. JSOM has a few key...

Overriding Email Headers within SharePoint

Note: This posting is not intended to be a tutorial on how to send email through REST on SharePoint but rather document the attempts to override the Reply-To within the REST service to prove that some headers cannot be added or overridden. Within SharePoint Online email can be sent out to internal users using JavaScript to communicate with the built in REST services. One minor downside is that the email...

SharePoint Online: Refinable Managed Properties and Limitations

SharePoint Online (SPO) differs slightly with managed property usage than 2013. Unlike 2013, in SPO the managed property will show however refinable and sortable are greyed out. Microsoft has written out out an approach to having these properties refinable: When you create a new site column in a SharePoint list, the crawler picks up the name of the site column as a new crawled property. SharePoint automatically maps the new...

SharePoint App (Add-In) Search Requests Error: Cannot find resource for the request search

I’ve been learning a few things when working with the SharePoint API while on a SharePoint hosted app. Everything seemingly worked well for most of my REST requests such as GetListByTitle but when it came to search all I could get was a single simple error. Microsoft.SharePoint.Client.ResourceNotFoundException, with error message ‘Cannot find resource for the request search.’ Basically this will be generated if you call /_api/search/postquery or /_api/search/query while trying...

SharePoint Online: The endpoint address does not match the app’s endpoint

A few weeks back I was investigating an issue with a SharePoint Add-in. I had created a second App file to point to the new App location on Azure. The Client ID remained the same within the web app (as its contained within web.config) and the app file upon publish. That’s when I received: “The endpoint address ‘https://myapp-QA.azurewebsites.net/Services/AppEventReceiver.svc’ does not match the app’s endpoint ‘myapp-DEV.azurewebsites.net’.” I had gone through all...

December 24, 2015 | No Comments

Creating Expandable Syntax Code Containers – SyntaxHighlighter Evolved

One of my pet peeves with sites that share code is that often snippets will be hard to copy, taking in markup or line numbers, or the fact that it’s just too hard to read on the website due to sizing. For this blog I have been using SyntaxHighlighter Evolved which works well. My only issue was when I switched to a thinner design it hurt readability of code when...

Export Any SharePoint WebPart In a Click With This Bookmarklet or JavaScript

Take a peek, see that little Export Me in the above picture? I just had to click my bookmarklet to produce this link which allows for a direct export of any visible web part. This uses a trick I found on CHUVASH.eu which highlights that there’s a special ‘exportwp.aspx’ page within SharePoint that when handed the webpart GUID and page url will provide the export XML download. Neat? Neat. Bookmarklet...