HtmlElement.Id Property

Gets the identifier of the current HTML element.

Namespace:  System.Windows.Browser
Assembly:  System.Windows.Browser (in System.Windows.Browser.dll)

Syntax

'Declaration
Public Property Id As String
public string Id { get; set; }

Property Value

Type: System.String
An HTML element ID string if the current element has an identifier; otherwise, an empty string.

Exceptions

Exception Condition
ArgumentException

The property is set to an empty string.

ArgumentNullException

The property is set to nulla null reference (Nothing in Visual Basic).

Version Information

Silverlight

Supported in: 5, 4, 3

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.