LogProvider.CreationName 속성

정의

런타임에서 LogProvider 개체의 인스턴스를 만드는 데 사용되는 문자열을 반환합니다. 이 속성은 읽기 전용입니다.

public:
 property System::String ^ CreationName { System::String ^ get(); };
public string CreationName { get; }
member this.CreationName : string
Public ReadOnly Property CreationName As String

속성 값

로그 공급자의 이름 또는 식별자(GUID)를 포함하는 문자열입니다.

구현

예제

다음 코드 예제에서는 로깅이 활성화된 패키지를 로드합니다. 패키지를 LogProviders 로드한 후 컬렉션이 만들어지고 컬렉션의 각 로그 공급자가 열거되어 각 속성 CreationName에 대한 값을 인쇄합니다.

using System;  
using System.Collections.Generic;  
using System.Text;  
using Microsoft.SqlServer.Dts.Runtime;  
using Microsoft.SqlServer.Dts.Tasks.DMQueryTask;  

namespace LogProvider_Properties_Test  
{  
    class Program  
    {  
        static void Main(string[] args)  
        {  
            // The package is one of the SSIS samples,  
            // modified to log information to the "SSIS  
            // log provider for Text files".  
            string mySample = @"C:\Program Files\Microsoft SQL Server\100\Samples\Integration Services\Package Samples\CalculatedColumns Sample\CalculatedColumns\CalculatedColumns.dtsx";  
            // Create the Application, and load the sample.  
            Application app = new Application();  
            Package pkg = app.LoadPackage(mySample, null);  

            // Get the LogProviders collection from the package.  
            LogProviders logProvs = pkg.LogProviders;  
            foreach (LogProvider logProv in logProvs)  
            {  
                Console.WriteLine("ConfigString:   {0}", logProv.ConfigString);  
                Console.WriteLine("CreationName    {0}", logProv.CreationName);  
                Console.WriteLine("DelayValidation {0}", logProv.DelayValidation);  
                Console.WriteLine("Description     {0}", logProv.Description);  
                Console.WriteLine("HostType        {0}", logProv.HostType);  
                Console.WriteLine("ID              {0}", logProv.ID);  
                Console.WriteLine("InnerObject     {0}", logProv.InnerObject);  
                Console.WriteLine("Name            {0}", logProv.Name);  
             }  
        }  
    }  
}  
Imports System  
Imports System.Collections.Generic  
Imports System.Text  
Imports Microsoft.SqlServer.Dts.Runtime  
Imports Microsoft.SqlServer.Dts.Tasks.DMQueryTask  

Namespace LogProvider_Properties_Test  
    Class Program  
        Shared  Sub Main(ByVal args() As String)  
            ' The package is one of the SSIS samples,  
            ' modified to log information to the "SSIS  
            ' log provider for Text files".  
            Dim mySample As String =  "C:\Program Files\Microsoft SQL Server\100\Samples\Integration Services\Package Samples\CalculatedColumns Sample\CalculatedColumns\CalculatedColumns.dtsx"   
            ' Create the Application, and load the sample.  
            Dim app As Application =  New Application()   
            Dim pkg As Package =  app.LoadPackage(mySample,Nothing)   

            ' Get the LogProviders collection from the package.  
            Dim logProvs As LogProviders =  pkg.LogProviders   
            Dim logProv As LogProvider  
            For Each logProv In logProvs  
                Console.WriteLine("ConfigString:   {0}", logProv.ConfigString)  
                Console.WriteLine("CreationName    {0}", logProv.CreationName)  
                Console.WriteLine("DelayValidation {0}", logProv.DelayValidation)  
                Console.WriteLine("Description     {0}", logProv.Description)  
                Console.WriteLine("HostType        {0}", logProv.HostType)  
                Console.WriteLine("ID              {0}", logProv.ID)  
                Console.WriteLine("InnerObject     {0}", logProv.InnerObject)  
                Console.WriteLine("Name            {0}", logProv.Name)  
            Next  
        End Sub  
    End Class  
End Namespace  

샘플 출력:

ConfigString:

CreationName DTS. LogProviderTextFile.1

DelayValidation False

설명 CSV 파일에 이벤트에 대한 로그 항목을 씁니다.

HostType LogProvider

ID {1E107E39-DB79-4F02-B8A7-61D88F2DEF63}

InnerObject System.__ComObject

텍스트 파일에 대한 SSIS 로그 공급자 이름 지정

설명

를 사용하여 CreationName컬렉션에 로그 공급자를 추가할 수 있습니다. 생성 이름을 ProgID라고도 합니다. 로그 공급자에 할당된 ProgID 목록은 다음을 참조하세요 Add.

적용 대상