Author Archives: Abhijit Jana

About Abhijit Jana

Abhijit runs the Daily .NET Tips. He started this site with a vision to have a single knowledge base of .NET tips and tricks and share post that can quickly help any developers . He is a Former Microsoft ASP.NET MVP, CodeProject MVP, Mentor, Speaker, Author, Technology Evangelist and presently working as a .NET Consultant. He blogs at http://abhijitjana.net , you can follow him @AbhijitJana . He is the author of book Kinect for Windows SDK Programming Guide.

Step-back while debugging with IntelliTrace in Visual Studio 2017

The recent updates of Visual Studio 2017 (version 15.5 Preview) comprise with several sets of new features and improvements. Once of such great enhancement is “step-back” while debugging. Now, you can perform a step-backward and forward while debugging your code with IntelliTrace Debugging. Visual Studio takes snapshots of each breakpoint while debugging and allows us to take a step back with the previous state of data.

Continue reading

Did you know – “Developer News” section in Start Page, when collapsed, shows you a notification in case there are feed updates – Visual Studio 2017?

Visual Studio 2017 has a re-designed the start page that prioritizes and rearranged items, which made it cleaner and easy to access on the things that you need to get it started. Be it a Most Recent Used (MRU) project lists, opening an existing project or even choosing the project template for your new project – start page has everything arranged and categorized. Additionally, there is also a “Developer News” section that gives you latest and relevant post related to Visual Studio (same as News section of the earlier versions of Visual Studio).

Continue reading

Picking up New Project Template right from the Start Page in Visual Studio 2017

Visual Studio 2017 having a reshaped start page. Be it with getting started documents, picking up your recent projects, or evening creating a new project. This has everything to get you started. Creating the new project has an altogether a new section to start up a new project. When you select the “Create new project…” option, you will find the traditional “New Project” dialog window appears and from there you can select the project templates to take it forward. In an additional features, the New project section in start page shows the list of recently used project templates.

Continue reading

Set Conditions for Exception in Visual Studio 2017

In Visual Studio, you can use Exception Settings Window to manage the exceptions – for which exception to break, at which point to break, to add or deleting exceptions. The Exception Settings windows for Visual Studio is there for quite some time. You can open the exception settings window by navigating from Debug -> Windows -> Exception Settings. With Visual Studio 2017, it has some additional features and which is quite useful. You can now set the condition on the exception in the Exception settings Windows. With that, only when there is a matched condition, IDE will throw an exception.

Continue reading

Did you know – “Attach to Process” dialog window now has a “Process Filtering” option in Visual Studio 2017 ?

During debugging in Visual Studio, attaching to a process is a very common activity, and as a developer, we are all familiar with it. We can attach the Visual Studio debugger to a running process by navigating from Debug > Attach to Process (Ctrl+Alt+P) and then select the specific process from the Attach to Process dialog box.

Continue reading

Expression Bodied Local Function in C# 7.0

Expression-bodied methods” were introduced with C# 6.0, that simplify the syntactic expression for methods in C#.  C# 7.0 extend this features for several new members including constructor, destructor, property assessors etc, and we have seen this one of our previous post – Expression – Bodied Members in C# 7.0. C# 7.0, also introduced local function by defining the helper function with in the method itself – Helper function for your local method – Local Function in C# 7.0.

Continue reading

Improve code readability using Digit Separator in C# 7.0

During development, often we use literal in our code. They are the fixed values which may not alter during the code execution. Sometime these values are large, and sometime small.  If it is small, it’s ok. If it long representation, it could be hard to read. Making them separate could help read them better.  C# 7.0 allows ‘_’ (underscorein literals for improving the readability of your code.

Continue reading

Directly throw Exception as an Expression – Throw expressions in C# 7.0

In one of our previous post, Expression – Bodied Members in C# 7.0 , we have seen how C# 7.0 extended the expression bodied members features for several new members including  constructor, destructor, property assessors etc. C# 7.0 also introduces throw expressions, using which you can now throw an exception along with expression-bodied members, conditional expressions or even null-coalescing operations. Let’s have a look how it works.

Continue reading

Did you know – you can just “copy the code” as well from C# Interactive Window ?

The Interactive Window in Visual Studio is a great utility to play around the code, language features, API’s and other .NET framework features.   The Interactive Window also support features like IntelliSense, syntax highlighting and navigating through executed commands. Previously we have seen several tips around the C# Interactive Window, but there is one very interesting feature you may overlooked, in fact, I missed that as well.   The Interactive Window, allows you to copy the source code only (Copy Code), so that you can directly paste them back to your main code editor.

Continue reading

How To customize “Structure Guide Lines” Colors in Visual Studio 2017 ?

In Visual Studio 2017   dotted structure guide lines in your code, between the curly braces ({}), helps in identifying the individual blocks easily.  Also, hover over on the lines, it will shows the tooltip with opening of that block and its parents. In the previous post we have seen how to Turning On/Off “Structure Guide Lines” in Visual Studio 2017 .  The Structure Guide Lines in the Visual Studio editor displayed with a light gray color. While this is the default color provided with Visual Studio, you can customize it if you want.

Continue reading