Programs are complicated—when in development, many tasks need remembering. We track them in Visual Studio with TODO comments.
These comments help organize our projects. We list to-do items in a central place. Variations on the "TODO" syntax are supported, so this feature is more usable.
TODO comments allow Visual Studio to maintain a central list of tasks, which it reads from many different places. The Task List
shows all the TODO comments in your project.
List
. A recent version of Visual Studio is needed.class Program
{
public static void Main()
{
//todo: fix dialog windows
//TODO: work on SQL guide
// Todo new screenshot
System.Console.WriteLine("OK");
}
}OK
With Visual Studio Code, there is minimal support for "todo" without installing an extension. A file named todo will have a special "check box" icon.
Example todo file names: "Todo Tree" "TODO-Highlight" "todo" ...
Note that you have some flexibility with these tokens. The strings "todo," TODO and TODO all work equally well. Visual Studio's parser allows some variation.
We looked at TODO comment syntax in the Visual Studio IDE. You can go through your project and put TODO comments everywhere you need to do something.
UNDONE and HACK are a couple other predefined comment tokens. Experiment and find what suits your style the best, so you can be as productive as you want to be.