NamedRange.EntireColumn Özellik
Alır bir Microsoft.Office.Interop.Excel.Range içeren tüm sütun (veya sütunlar) temsil eden NamedRange Denetim.
Ad alanı: Microsoft.Office.Tools.Excel
Derleme: Microsoft.Office.Tools.Excel (Microsoft.Office.Tools.Excel.dll içinde)
Sözdizimi
'Bildirim
ReadOnly Property EntireColumn As Range
Get
Range EntireColumn { get; }
Özellik Değeri
Tür: Microsoft.Office.Interop.Excel.Range
A Microsoft.Office.Interop.Excel.Range içeren tüm sütun (veya sütunlar) temsil eden NamedRange Denetim.
Örnekler
Aşağıdaki kod örneği oluşturur bir NamedRange ve kenarlık rengi içeren satırları ve sütunları ayarlar NamedRange Yeşil.
Bu örnek, bir belge düzeyinde özelleştirme için bulunur.
Private entireRowAndColumnRange As Microsoft.Office.Tools.Excel.NamedRange
Private Sub HighlightColumnAndRow()
entireRowAndColumnRange = Me.Controls.AddNamedRange( _
Me.Range("C3", "E5"), "entireRowAndColumnRange")
' Set the style of the column and row borders to xlSlantDashDot.
Me.entireRowAndColumnRange.EntireColumn.Borders.LineStyle = _
Excel.XlLineStyle.xlSlantDashDot
Me.entireRowAndColumnRange.EntireRow.Borders.LineStyle = _
Excel.XlLineStyle.xlSlantDashDot
End Sub
Microsoft.Office.Tools.Excel.NamedRange entireRowAndColumnRange;
private void HighlightColumnAndRow()
{
entireRowAndColumnRange = this.Controls.AddNamedRange(
this.Range["C3", "E5"], "entireRowAndColumnRange");
// Set the style of the column and row borders to xlSlantDashDot.
this.entireRowAndColumnRange.EntireColumn.Borders.LineStyle =
Excel.XlLineStyle.xlSlantDashDot;
this.entireRowAndColumnRange.EntireRow.Borders.LineStyle =
Excel.XlLineStyle.xlSlantDashDot;
}
.NET Framework Güvenliği
- Anında arayanlar için tam güven. Bu üye kısmen güvenilen kodla kullanılamaz. Daha fazla bilgi için bkz. kısmen güvenilir kod tarafından Kitaplıklar kullanma.