Started a new MCSD certification : Azure Solutions Architect

Started a new MCSD certification : Azure Solutions Architect

Last week I decided to get started with a new MCSD certification: Azure Solutions Architect. In a world where more customers want to take advantage of Microsoft Azure, it’s important to get my knowledge up-and-running. At my own company we are using Microsoft Azure for almost all our backend tasks. We are hosting sites, web services, SQL Azure databases and for example Virtual Machines with a regular SQL Server installation. We can manage them fine, but for some real troubleshooting…

Read More Read More

Missing dropdown controls in the code editor

Missing dropdown controls in the code editor

Today I encountered a strange behavior in the code editor of Visual Studio 2015. The dropdown controls with the list of controls and procedures were missing! I thought it was a glitch in the software; as it still not officially released, you could expect some issues. But no… I discovered today that it is a feature you can enable and disable. Go to Tools > Options > Text Editor > All Languages and simple check the option ‘Navigation bar’. Some…

Read More Read More

Year first date literals in Visual Basic .NET

Year first date literals in Visual Basic .NET

Since I write on a daily base unit tests, I’m wondering more and more why there is not an easy – and especially unambiguous – way to provide a hardcoded date to a variable or procedure argument. Do you know, without any doubt, what this date actually means? Was I born on the 5th of June or the 6th of May? Visual Basic .NET will support now a good ISO-standard, which starts with the year. It follows the convention of…

Read More Read More

Show generated SQL of Entity Framework in Visual Basic .NET

Show generated SQL of Entity Framework in Visual Basic .NET

When you are writing LINQ queries against an Entity Framework context, you don’t have to worry about the SQL which is generated and executed. However, in some cases you may be interested in this SQL. It’s quite easy to switch on a logging mechanism which will be display all executed SQL in your Debug window. You have to provide an Action to the DbContext.Database.Log property. You provide a lambda with the functionality you want. If you want you can log…

Read More Read More

Query a CSV file with LINQ and Visual Basic .NET

Query a CSV file with LINQ and Visual Basic .NET

Once in a while I’m still surprised by the functionality of LINQ. I saw a question on the Internet from a developer who asked if it is possible to query against Comma Separated Values (CSV) in a file. Based on one of the answers I wrote this post, because it’s really great what you can do with so less source code. As you probably already knew, I’m a big fan of LINQPad, which I will use to demo my examples….

Read More Read More

Saving customized Window Layouts

Saving customized Window Layouts

I think it’s not new for you that in Visual Studio you can customize the position, size and behavior of windows to create window layouts that work best for various development workflows. When you customize the layout, Visual Studio remembers it. For example, if you change the docking location of the Properties Window and then close Visual Studio, the next time that you start, even if you are working on another computer, the Properties Window will be docked in that…

Read More Read More

Left Outer Join in LINQ with Visual Basic .NET

Left Outer Join in LINQ with Visual Basic .NET

Many developers encounters problems when trying to mimic the functionality of a Left Outer Join in LINQ. To be honest, the needed code is on first sight a bit strange. You can use a Group Join … Into .. and the DefaultIsEmpty() method. Let’s start with a regular (Inner) Join example. It uses the NorthWnd database and will retrieve all customers with at least one order.

Use a custom connectionstring in Entity Framework

Use a custom connectionstring in Entity Framework

For a customer I needed to customize the way an Entity Framework 6 database-first project connects to a SQL Server database. Normally you specify the connectionstring including some metadata about the model in the app.config file. You can choose either to use Windows Authentication or SQL Authentication. If you want to use SQL Authentication you must provide the username and password. These are by default not encrypted and my customer did not like the idea that users who have access…

Read More Read More