/* BeejBløg */

Mar 4, 2017 - 2 minute read - Comments -

ASP.Net Controller API nuggets

Write Directly to Response Stream Stack-o basically covers this already but kinda danced around how minimal the code can really be for the basic scenario… 123456789101112131415161718192021222324252627 //e.g. $.ajax(url, { procName: "", parms: {deliveryDate:"3/2/2016"}, returnParmName: "" }, ...) public class GenericProcArgs { public string procName { get; set; } //from: https://stackoverflow.com/questions/5022958/passing-dynamic-json-object-to-c-sharp-mvc-controller //super convenient way to receive JS object with arbitrary properties to be fed straight to proc parms public dynamic parms { get; set; } /// <summary> /// whether to titleCase the JSON property names (handy for feeding auto built datagrids) /// </summary> public bool titleCase { get; set; } = false; public string returnParmName { get; set; } } //here's the beef.

Mar 2, 2017 - 1 minute read - Comments -

Kendo UI Nuggets

Grid doesn’t like spaces in dataSource field names (I happen to be subscribing to KnockoutJS observable here to receive data feed but that naturally depends on your framework of choice.) Typical Kendo JS error: invalid template Particularly note the way the columns property is generated. 1234567891011121314151617181920212223242526272829303132333435363738 sigCapVm.packingSlips.subscribe(function (newval) { var gridPackingSlips = $("#gridPackingSlips"); var kgrid = gridPackingSlips.data("kendoGrid"); if (kgrid && kgrid.columns.length) kgrid.dataSource.data(newval); else { if (kgrid) kgrid.destroy(); gridPackingSlips.kendoGrid({ //workaround for autogenerating columns with spaces //from: https://www.

Mar 2, 2017 - 1 minute read - Comments -

Nuget Cheatsheet

tip command line uninstall all packages matching pattern `get-package speaking of Humanzier, just install Humanizer.Core to get English only ↩

Feb 7, 2017 - 6 minute read - Comments -

Updating 2006 MacBook Pro to Win 10

Background There’s a fair amount of noise to wade through out there on this topic… this post is a humble gathering of the current state, cira February 2017… once we get the various bits lined up, it’s surprisingly smooth sailing with FULL compatibility under Windows 10 x64, even the latest “Anniversary Edition”… over 10 years later something as complex as Windows maintaining this much hardware compatibility is pretty amazing in our industry.

Jan 31, 2017 - 1 minute read - Comments -

Fixing OpenSSL on WordPress Windows PHP 5.6+

Background: i ran into OpenSSL errors during the Disqus plugin setup. there’s tons of hits suggesting various solutions, below is the very simple solution that worked for me… Sample error messages: SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed<br /> Failed to enable crypto in ... TL;DR: download latest cacert.pem place it in a pertinent folder (e.g. $\wp-includes\certificates) edit your php.ini > openssl.cafile={full path to cacert.pem}

Jan 24, 2017 - 2 minute read - Comments -

JavaScript (ES7) async wrappers perfect for Chrome.Bookmarks API

Background: I tasked myself with a little project to sync my Chrome Bookmarks Bar with my Diigo links. Chrome’s Bookmarks API is very straightforward but it is a traditional async callback style call… so it became a good opportunity for me to cozy up to EcmaScript v7’s (ES7) async/await support… since this is done in a Chrome Extension, it lends itself to this hard dependency on ES7 syntax… async/await is supported as of Chrome v55 in Dec.