By John Bubriski on May 2, 2012
(Disclaimer: This is not a completely scientific analysis. My conclusions are based solely on the user reviews on various retail sites. Do not blame me if you Crucial M4 dies. Yes, that is still a possibility just as it is with any SSD, Hard Drive, or any other piece of hardware.) So far I’ve owned [...]
Posted in Hardware | Tagged Computers, Crucial M4, Hard Drives, Laptops, Programming, SSD |
By John Bubriski on May 2, 2012
Disclaimer: I did pay $19.95 for this product, but I may receive a complimentary license in return for writing this review (Scroll to the end of the article for more info). Background Code snippets in Visual Studio are great. I Code Snippets all the time! My favorite is probably one of the simpler ones: prop. [...]
Posted in Programming | Tagged .NET Framework, C#, Code, Code Snippets, Productivity, Visual Studio |
By John Bubriski on April 25, 2012
Not going to go into why you should backup, but here is how I handle the things that matter to me: Code, Documents, PC Games, and Photo and Video. Code This one is pretty much a no-brainer for me. Use Bitbucket to host your private repositories for free, and use GitHub to host your public [...]
Posted in Programming, Technology | Tagged Backups, Cloud, NAS, Photography |
By John Bubriski on April 10, 2012
The Setup You’re building a RESTful web service, and your technology stack looks something like this: ASP.NET MVC 4 w/ Web API Entity Framework Code First (I’m on 4.3.1, available via Nuget) Newtonsoft JSON.Net (I’m on 4.5.1, available via Nuget) We’ll pull the data out of the database using EF and setup the ASP.NET Web [...]
Posted in Programming | Tagged .NET Framework, ASP.NET, ASP.NET MVC, ASP.NET Web API, Circular References, Entity Framework, JSON, JSON.Net, REST, Serialization |
By John Bubriski on March 19, 2012
So I started a new open source project called Shing. It’s goal is simple: Scrape an Amazon Wishlist, get all the Product ID’s and generate the Amazon short links to the products. I was showing the code to my colleagues when Joey, a friend and former coworker, offered some suggestions to improve the code. This [...]
Posted in Programming | Tagged .NET Framework, Amazon, C#, Code, Open Source, Regex, WebClient, Wishlist |
By John Bubriski on February 28, 2012
I forget why I needed to do this, but I was doing some heavy development around Kentico‘s BizForm‘s at the time and needed to pull back a list of alternative forms for a given BizForm. It’s not very complex, but it might not be obvious if you’re not familiar with Kentico’s database structure and their [...]
Posted in Kentico, Programming | Tagged Kentico Alternative Forms, Kentico BizForms, SQL |
By John Bubriski on February 27, 2012
Developing a custom web part or module and want to log some events into the Kentico Event Log? Here is some sample code to get you started. Logging Exceptions: var eventLogProvider = new EventLogProvider(); eventLogProvider.LogEvent("E", eventName, ex); Logging Custom Events: var eventLogProvider = new EventLogProvider(); eventLogProvider.LogEvent("E", DateTime.Now, "source", "code"); FYI, I believe that the EventLogProvider [...]
Posted in Kentico, Programming | Tagged .NET Framework, ASP.NET, C#, Code, Kentico API Programming, Kentico CMS, Kentico Event Log, Kentico Module Development |
By John Bubriski on February 23, 2012
So you installed the ASP.NET MVC 4 Beta and followed the Web API introduction over at the ASP.NET website. Great! You now have a nice HTTP based API that plays nicely with jQuery and other client side JavaScript libraries, and even other server-side technologies. But how exactly do we perform server side consumption of that API in [...]
Posted in Programming | Tagged .NET Framework, ASP.NET, ASP.NET MVC, ASP.NET Web API, C#, Code, HTTP, HttpClient, jQuery, JSON, REST, WCF, Web Services, XML |
By John Bubriski on February 22, 2012
Here is a post I wanted to write a few months ago while I was actively developing Kentico based websites, but I never got the chance to finish it. The code should be solid, and I’ll explain it as best I can. If you’re working with BizForm’s programmatically you’re going to need to get the ID [...]
Posted in Kentico, Programming | Tagged .NET Framework, ASP.NET, C#, Code, Kentico API Programming, Kentico BizForms, Kentico CMS |
By John Bubriski on February 21, 2012
Need to get all the files contained in a directory, recursively searching through sub directories? No problem! Here is how to do it without writing your own recursive function: var fileNames = Directory.GetFiles(directoryName, "*.*", SearchOption.AllDirectories); That’s it! No explicit recusrion required! If you want to do searching where you can stop when a given file [...]
Posted in Programming | Tagged .NET Framework, C#, Code, Files and I/O |