| ITagManagerById Method |
Retrieves a tag by its unique identifier.
Namespace:
EdaIntegrationContract.Tagging
Assembly:
EdaIntegration.Contract (in EdaIntegration.Contract.dll) Version: 7.6
Syntax Parameters
- id
- Type: SystemInt32
The unique identifier of the tag to find.
Return Value
Type:
ITagThe tag with the supplied unique identifier.
Exceptions Exception | Condition |
---|
EdaApiException | Thrown if a tag cannot be found with the specified Id. |
Examples
The following example demonstrates retrieving a tag using its id.
using EdaIntegrationContract;
using EdaIntegrationContract.Case;
using EdaIntegrationContract.Tagging;
class Sample
{
static void Main()
{
var edaIntegration = new EdaIntegration().ConnectToExplore();
ICase edaCase = edaIntegration.Cases.OpenCaseByName("Case 1");
ITag tag = edaCase.Tags.Create("Privileged");
ITag itemById = edaCase.Tags.ById(tag.Id);
Console.WriteLine("Id: {0}", itemById.Id);
Console.WriteLine("Name: {0}", itemById.Name);
}
}
See Also