DTE dte = (DTE)GetService(typeof(DTE)); dte.ExecuteCommand("Build.BuildSolution");
DTE dte = (DTE)GetService(typeof(DTE)); dte.ExecuteCommand("Edit.Find"); dte.Find.FindWhat = "TODO"; dte.Find.Target = vsFindTarget.vsFindTargetCurrentDocument; dte.Find.Action = vsFindAction.vsFindActionFindAll; dte.Find.Execute();The `DTE ExecuteCommand` method belongs to the EnvDTE namespace, which is part of the Visual Studio SDK. It can be accessed by adding a reference to the `EnvDTE` assembly. Package/library: Visual Studio SDK.