I don't need a Solution!!

So the last thing you want to do is create a complete Solution in Visual Studio just to type out a few lines of code. Thanks to the Visual Studio 2015 Update 1 you don't need to create a solution. Just so we are clear this isn't knocking other tools like LINQPad. LINQPad is a great tool so this is just another tool to put in your toolbox. 

Welcome the C# Interactive Window in Visual Studio 2015!


Ok so this doesn't look like much but this window, introduced in the latest update for Visual Studio 2015, lets us use the Roslyn REPL features for C# . REPL stands for "Read Eval Print Loop". Basically it reads your code, evaluates it and you guessed it...prints feedback. You can even integrate the REPL features into your own app using the Roslyn APIs. The nice thing with the C# interactive window is that it provides Intellisense. The window allows you to type in expressions, statements and methods just like a normal .cs file.


All this makes it very easy to quickly test a theory out and get some feedback. No the below foreach loop is not a mystery to me...just an example.


Now the above code snippet is very simple and you may be asking what about third party APIs. Well we are in luck. using the "#r" directive we can import other DLLs. We can even load in script files using the "#load" directive. 

Again this is another tool in your toolbox. If your looking for a full featured tool besides Visual Studio, I would definitely check out LINQPad.  The C# Interactive Window reference is here . Hope this helps you and happy coding!