NativeExcel for .Net Developer's Reference

IName.Visible Property

Gets or sets a value that indicates whether the defined name is visible.

[Visual Basic]
PropertyVisibleAsBoolean
[C#]
boolVisible{get;set;}
[C++]
__propertyboolget_Visible();
__propertyvoidset_Visible(bool);
[JScript]
functiongetVisible():bool
functionsetVisible(bool);

Property Value

true if the defined name is visible; otherwise, false. The default value is true.

Example

This example hides the first defined name in the worksheet one.

[C#]
INames names = Workbook.Worksheets[1].Names;
if (names.Count > 0) names[1].Visible = false;
[VisualBasic]
Dim names As INames = Workbook.Worksheets(1).Names
If names.Count > 0 Then
   names(1).Visible = False
End If 
[C++]
INames* names = Workbook->Worksheets->Item[1]->Names;
if (names->Count > 0) 
   names->Item[1]->Visible = false;

See Also

IName Interface | NativeExcel Namespace