Posts

C# Dapper Repository

New Direction I had created a framework for a new Microsoft C# MVC web application at work using XML Serialization for the database to POCO conversion and straight ADO for data transmission. We had an architecture review and were asked to try Dapper instead. The word was that other units were using it. We looked around but didn't find anyone using Dapper Micro ORM with a repository pattern, especially for hierarchical data, so last weekend I set out to create one that I'm sharing on my Dropbox: https://www.dropbox.com/s/n5v1o2zdyhyvjyf/DapperDemo.zip?dl=0   This link is to a .zip file. Hopefully have all the goodies you need to view the code and run it.  The Zip Folder Contents In the “Database” folder I have a document with some description about the solution.  I also have 2 scripts to create and populate a simple database with 3 tables.  There is a Main table, a Child table with a many to one relationship to the Main table, and an Auxiliary table wi...

My Blog Hiatus

Image
I can't believe it's been almost 2 months since I posted anything. Where does the time go? It's probably been even longer since I did a photography post... I've been busy at work and have kind of neglected this blog. I've actually been kind of working on a blog sort of thing at work - a Tech Tip that I send out. I'm going to start posting them here too since they apply. Here's the first one:

Finally - I got an ASP.Net Core app to run! (Updated)

Image
Here I go again... I was following along with the Pluralsight course " Building a Web App with ASP.NET Core, MVC 6, EF Core, and Angular " but couldn't get the first demo app to run. I was stuck in Section 2 - Visual Studio! Bummer! I created a new ASP.Net Core app from scratch and tried to run it out of the box and got the error you see at right. I had zero luck finding a solution online. I searched through the code and the only place I found where there was a "type" property that was likely to be null (it's actually a string value in the file) was in the [app].vs\config\applicationhost.config file: <configuration> ... <configProtectedData>         <providers>             <add name="IISWASOnlyRsaProvider" type="" description="Uses RsaCryptoServiceProvider to encrypt and decrypt" keyContainerName="iisWasKey" cspProviderName="" useMachineContainer="true" useOAEP=...

Very quick - starting to look at MS ASP.Net Core, AngularJS

Image
A New Brain Yesterday at work we got a new employee whom I'll call Neesha. Actually, she came onboard a couple of days earlier but I was out due to surgery my wife needed. Neesha was brought on to work on a side project in my unit. I was very pleased to have someone to talk to about more modern software development technologies. She even suggested that the side project might be suitable to use ASP.Net Core and AngularJS . How cool! Not only was she looking at new technologies (well, new compared to what our mainly Classic ASP shop implements or even considers), but she qualified the considerations with statements along the lines of "if the technologies are suitable for the application and it's requirements"! A thinker! Woo hoo! Some Early Thoughts  I told her I wasn't very familiar with Core or Angular - I'd only had some passing exposure to it in the past few months. I told her that I'd spend some time this weekend looking at some Pluralsight...

You Had Me at TDD (Test Driven Development)

Image
Get On Board! As I may have mentioned, I'm an old programmer. When I went to college I learned a bit about testing my own software but it wasn't emphasized. At least not in the classes I took in the early 1980's. Somewhere along the line I started hearing about Test Driven Design but I'll admit, I don't remember when or where. "Uncle" Bob Martin at Software Craftsmanship In my latest spurt of actually studying software development, one of the sources I've been watching quite a bit on YouTube is "Uncle" Bob Martin. For younger software developers, his name may be more familiar than it is/was to me. Here's an example video:  https://www.youtube.com/watch?v=qkblc5WRn-U . There are a good number of Uncle Bob videos where he discusses TDD; he's one of those (or is the one) that developed the idea of TDD. Basically, TDD from Bob's perspective means you write a test and run it. It will fail, naturally. Then you write the cod...

C# 7 and Beyond!

Image
The Future is Now I watched an interesting YouTube yesterday about the Future of Microsoft C#. I have to admit that I've been on a spurt lately (starting this last February) of being interested once again in software development and a lot of my interest is due to C# (the instigator was getting back into Microsoft MVC with C#). I've been writing software to one extent or another since about 1980. Yeah, I'm an old dude - I'll turn 60 this year. I've been developing software as a primary occupation since 1997. 20 years. Before that I had always written software to some level to assist me in my jobs. In the Navy I wrote a small program on my HP-41CV programmable calculator that would solve passive targeting solutions for anti-submarine warfare (TMA if you're familiar with it). Since I was also tasked with being the secret materials officer, I wrote a database tool for tracking the secret materials. And it did not use an off the shelf database - I wrote my own ...

More Info from Microsoft RE: Visual Studio 2017 Upgrade Woes

Microsoft Responds I posted a few weeks ago about my problems that I encountered when upgrading Visual Studio 2017 from version 15.1 to 15.2 (those different ways that you refer to Microsoft applications sure are confusing. I wish they'd just refer to Visual Studio 2017 as Visual Studio 15 and when they have major updates to, say, 15.2, it would not be as cumbersome to discuss). I had posted my issue to the Visual Studio Developer Community  website which seems to be the new Microsoft website for everything Visual Studio (I wonder how long that will last?). I had some response from Microsoft representative Raja, and he pointed me in the direction of how to fix my upgrade woes. But eventually I un-installed every developer tool from Microsoft that I could, ran a bunch of CCleaner  registry cleanups and reboots and eventually got Visual Studio 2017 up and running again. I couldn't see how to close my post at the Visual Studio Developer Community (Microsoft reps have to do...