DtsPipelineComponentAttribute.IconResource Property
Gets or sets the icon used to represent the component in the toolbox.
命名空間: Microsoft.SqlServer.Dts.Pipeline
組件: Microsoft.SqlServer.PipelineHost (in microsoft.sqlserver.pipelinehost.dll)
語法
'宣告
Public Property IconResource As String
public string IconResource { get; set; }
public:
property String^ IconResource {
String^ get ();
void set (String^ value);
}
/** @property */
public String get_IconResource ()
/** @property */
public void set_IconResource (String value)
public function get IconResource () : String
public function set IconResource (value : String)
屬性值
A string that identifies the icon resource used to represent the component in the toolbox.
備註
This property controls the icons that are shown in the Data Flow toolbox and on the design surface of the data flow tab when the component is added to the data flow.
The Data Flow toolbox uses the 16x16, 16-color image type, while the design surface of the data flow tab uses the 32x32, 16-color image type. Both are default image types for icons created using Microsoft Visual Studio 2005.
The format of the string identifying the icon resource is a dotted notation, consisting of the name of the root namespace for the assembly, followed by a period, then the name of the icon file.
To embed an icon file as a resource in an assembly using Visual Studio 2005, create a new icon, and then set the Build Action attribute of the icon file to Embedded Resource in the Visual Studio Properties window.
範例
The following example shows a component class that provides an icon resource.
using System;
using Microsoft.SqlServer.Dts.Pipeline;
namespace DtsDocumentation
{
[DtsPipelineComponent(DisplayName="MyComponent",IconResource="DtsDocumentation.MyComponentIcon.ico")]
public class MyComponent : PipelineComponent
{
}
}
Imports System
Imports Microsoft.SqlServer.Dts.Pipeline
Namespace DtsDocumentation
<DtsPipelineComponent(DisplayName="MyComponent", IconResource="DtsDocumentation.MyComponentIcon.ico")> _
Public Class MyComponent
Inherits PipelineComponent
End Class
End Namespace
執行緒安全性
Any public static (Shared in Microsoft Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
平台
開發平台
如需受支援的平台清單,請參閱<安裝 SQL Server 2005 的硬體和軟體需求>。
目標平台
如需受支援的平台清單,請參閱<安裝 SQL Server 2005 的硬體和軟體需求>。
請參閱
參考
DtsPipelineComponentAttribute Class
DtsPipelineComponentAttribute Members
Microsoft.SqlServer.Dts.Pipeline Namespace