blog.codelab.co.nz
hexadecimal value 0x1F, is an invalid character publishing content in Umbraco – Humming Coder
http://blog.codelab.co.nz/2013/02/23/hexadecimal-value-0x1f-is-an-invalid-character-publishing-content-in-umbraco
February 23, 2013. February 23, 2013. Hexadecimal value 0x1F, is an invalid character publishing content in Umbraco. I was adding some content into a Umbraco content page when I attempted to publish the page I got a 500 error with the following error message:. Server Error in '/' Application. Hexadecimal value 0x1F, is an invalid character. Line 1, position 519. Exception Details: System.Xml.XmlException: ' , hexadecimal value 0x1F, is an invalid character. Line 1, position 519. February 23, 2013. Templa...
blog.codelab.co.nz
InvalidCastException after upgrading from ASP.NET MVC 3 to ASP.NET MVC 4 – Humming Coder
http://blog.codelab.co.nz/2013/07/16/invalidcastexception-after-upgrading-from-asp-net-mvc-3-to-asp-net-mvc-4
July 16, 2013. July 16, 2013. InvalidCastException after upgrading from ASP.NET MVC 3 to ASP.NET MVC 4. I have recently upgraded a MVC 3 application to MVC 4 but along the way en-counted some issues around upgrading references in the project. Specially, I got this error. System.InvalidCastException was unhandled by user code. Message=[A]System.Web.WebPages.Razor.Configuration.HostSection cannot be cast. To [B]System.Web.WebPages.Razor.Configuration.HostSection. Type A originates. I believe the better sol...
blog.codelab.co.nz
Upgrading MVC Project 2 to 4 and open it in VS 2012 – Humming Coder
http://blog.codelab.co.nz/2013/07/05/upgrading-mvc-project-2-to-4-and-open-it-in-vs-2012
July 5, 2013. July 5, 2013. Upgrading MVC Project 2 to 4 and open it in VS 2012. I have an old MVC 2 project that works fine in VS 2010. However, if you try and open the project in VS 2012 you will get a “incompatible” error and left with no way to upgrade the project to VS 2012. Here are some pointers to get it working (this is how I got it working for myself). In VS2010, upgrade your MVC project to version 4. You need to follow the upgrade steps for upgrading to MVC 2 – 3 first. July 5, 2013. Promed (P...
blog.codelab.co.nz
Method chaining with deferring object creation – Humming Coder
http://blog.codelab.co.nz/2014/07/01/method-chaining-with-deferring-object-creation
July 1, 2014. July 1, 2014. Method chaining with deferring object creation. I have decided to write a couple of posts about how I used Method Chaining to help solve and better handle the creation of test data within my Unit Tests. This post and the example code via GitHub shows how I created test data using Method Chaining in a more generic form. There will be more posts to come regarding how this test data gets persisted into a in-memory database which will get used in XUnit Tests. July 1, 2014.
blog.codelab.co.nz
Script error when using RichTextEditor type in Razor macro – Umbraco – Humming Coder
http://blog.codelab.co.nz/2012/12/09/script-error-when-using-richtexteditor-type-in-razor-macro-umbraco
December 9, 2012. December 9, 2012. Script error when using RichTextEditor type in Razor macro – Umbraco. I came across this issue when trying to check if the RichTextEditor property had any content before rendering it to the display. Examine the following code:. Var thisNode = Model;. Div class=text-widget @thisNode.MyRichContent /div. This causes a script error because Umbraco thinks MyRichContent is a object type. December 9, 2012. You must be logged in. To post a comment. Related Content by Tag.
blog.codelab.co.nz
Knockout.js – Humming Coder
http://blog.codelab.co.nz/category/knockout-js
Coding is music to my ears. There are 2 posts filed in Knockout.js. Knockout Validation with Bootstrap Popover. I wanted to use Twitter’s Bootstrap Popover’s to let the user know they need to enter values into each of the form’s inputs. On top of Knockout’s Validation, I decided to create a custom Knockout binding that allows me to check if the Knockout observable is valid and either show or hide the popover with the error message. See the image below for the final result. The mark up is. Var self = this;.
blog.codelab.co.nz
Get All Nodes By DocumentType – Humming Coder
http://blog.codelab.co.nz/2013/01/13/get-all-nodes-by-documenttype
January 13, 2013. January 13, 2013. Get All Nodes By DocumentType. The following code describes how to get all the nodes by a particular document type across the whole Umbraco site. It uses a recursive method so if you add this as a macro I would suggest caching to reduce the number of times this method runs. Using System.Collections.Generic;. Using System.Linq;. Using System.Web;. Using umbraco.presentation.nodeFactory;. Private const int CONST NODEAMOUNT = 10;. List Node foundNodes = new List Node ();.
blog.codelab.co.nz
jQuery – Humming Coder
http://blog.codelab.co.nz/category/jquery-2
Coding is music to my ears. There are 5 posts filed in jQuery. Knockout Validation with Bootstrap Popover. I wanted to use Twitter’s Bootstrap Popover’s to let the user know they need to enter values into each of the form’s inputs. On top of Knockout’s Validation, I decided to create a custom Knockout binding that allows me to check if the Knockout observable is valid and either show or hide the popover with the error message. See the image below for the final result. The mark up is. If you have quite a ...
blog.codelab.co.nz
ASP.NET – Humming Coder
http://blog.codelab.co.nz/category/aspnet
Coding is music to my ears. There are 19 posts filed in ASP.NET. This is page 1. InvalidCastException after upgrading from ASP.NET MVC 3 to ASP.NET MVC 4. I have recently upgraded a MVC 3 application to MVC 4 but along the way en-counted some issues around upgrading references in the project. Specially, I got this error. System.InvalidCastException was unhandled by user code. Message=[A]System.Web.WebPages.Razor.Configuration.HostSection cannot be cast. Source=System.Web.WebPages.Razor. I believe the bet...
SOCIAL ENGAGEMENT