| Visual Basic (Declaration) | |
|---|---|
<ComVisibleAttribute(False)> Public NotInheritable Class LayerResult Inherits Result | |
| Visual Basic (Usage) | Copy Code |
|---|---|
| |
| C# | |
|---|---|
[ComVisibleAttribute(false)] public sealed class LayerResult : Result | |
This example demonstrates how you can create a LayerResult and set its Layer property in the Execute
method of a custom task class; in this case you should create the LayerResult, create a Layer without
connecting it, and set the LayerResult.Layer property; as long as the AutoConnect property of the
LayerResult is true, when the LayerResult is updated into the TaskContext then the layer will
automatically be connected. In the code below it is assumed that there are parameters called
Workspace and Dataset in the parameterset passed to the Execute method which determine the data that
the new LayerResult is connected to; alternatively it may be typical for a Task to connect to a web
service and retrieve the data to display for the LayerResult.
| C# | Copy Code |
|---|---|
// Set up the Layer for the ResultLayer. | |
| Visual Basic | Copy Code |
|---|---|
' Set up the Layer for the ResultLayer. | |
System.Object
ESRI.ArcGIS.E2API.Result
ESRI.ArcGIS.E2API.LayerResult
Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family
This class was added to the E2API at version 1.0.0.348.



Copy Code