Using Reflection to retrieve Entity Framework Data using a Column Name String

If you ever need to retrieve data from EF using the name of a column, rather than the built in Intellisense, then the following vb.net code snippet may help. GetType(TypeOfEntity).GetProperty(NameOfColumn).GetValue(ActualEntity, Nothing)TypeOfEntity is the name of the Entity from which you wish to retrieve data. NameOfColumn is obviously the Name of the Column from which you [...]

By |2017-07-24T08:33:19+01:00November 20th, 2012|.Net Framework, C#, Data, Entity Framework, VB.net, Visual Studio|0 Comments

Windows Forms App with Splash Screen Throws–“Invoke or BeginInvoke cannot be called on a control until the window handle has been created.” Exception

I’ve come across a bug in the .Net Framework when developing a Windows Forms app, which has a Splash Screen. On some users machines, the application threw a “Invoke or BeginInvoke cannot be called on a control until the window handle has been created.” exception at startup. This is seemingly to do with code executing [...]

By |2012-10-17T11:36:00+01:00October 17th, 2012|.Net Framework, Bugs, VB.net, Visual Studio|0 Comments

Command Line Parameter trailing backlash problem

I am currently working on a small console application which takes in a path name via the Command Line Parameters, parses the given path, and produces an XML file listing each folder and file. I am running the application as a Post Build event in Visual Studio, passing in the $(TargetDir) macro as; "c:Program FilesCreateUpdateXMLCreateUpdateXML.exe" [...]

By |2012-09-25T11:23:00+01:00September 25th, 2012|Bugs, File Access, VB.net, Visual Studio|0 Comments

MVVM: Binding a Linq Query result to a DataGrids’ ItemSource doesn’t update the UI

While creating Desktop Applications using WPF, I always employ the MVVM model if I can. This model is not only great at developing testable n-tier applications, but of course is also highly recommended by Microsoft. However, as with most software development, there are nearly always specific methods to employ for certain processes and functions. One [...]

By |2017-07-24T08:33:19+01:00September 21st, 2012|Data, MVVM, VB.net, Visual Studio|0 Comments

Visual Studio 2010 Source Control using Windows + Git + Git Extensions + DropBox

The following lays out a way to use Git + Git Extensions + Drop Box with an existing Visual Studio 2010 project. This will allow you to collaborate across multiple PC’s on the same project. There may be quite a few steps, but it’s all quite simple stuff… Install Git Install Git Extensions Install Drop [...]

By |2011-05-29T22:48:00+01:00May 29th, 2011|DropBox, Git, Source Control, Visual Studio|0 Comments