OutputGroup.DisplayName 属性
获取在用户界面中用于此输出组的名称。
命名空间: EnvDTE
程序集: EnvDTE(在 EnvDTE.dll 中)
语法
声明
ReadOnly Default Property DisplayName As String
string this { get; }
property String^ default {
String^ get ();
}
abstract DisplayName : string with get
function get DisplayName () : String
属性值
类型:String
一个字符串,表示在用户界面中用于此输出组的名称。
备注
DisplayName 返回输出组在环境中所显示的名称。
示例
Sub DisplayNameExample(ByVal dte As DTE2)
' Before running this example, open a project.
Dim proj As Project = dte.Solution.Projects.Item(1)
Dim groups As OutputGroups = _
proj.ConfigurationManager.ActiveConfiguration.OutputGroups
Dim group As OutputGroup
Dim msg As String = proj.Name & _
" has the following output groups:" & vbCrLf & vbCrLf
For Each group In groups
msg &= " " & group.DisplayName & vbCrLf
Next
MsgBox(msg)
End Sub
public void DisplayNameExample(DTE2 dte)
{
// Before running this example, open a project.
Project proj = dte.Solution.Projects.Item(1);
OutputGroups groups =
proj.ConfigurationManager.ActiveConfiguration.OutputGroups;
string msg = proj.Name + " has the following output groups:\n\n";
foreach (OutputGroup group in groups)
msg += " " + group.DisplayName + "\n";
MessageBox.Show(msg);
}
.NET Framework 安全性
- 对直接调用方的完全信任。此成员不能由部分信任的代码使用。有关详细信息,请参阅通过部分受信任的代码使用库。