Job.DateCreated Job.DateCreated Job.DateCreated Property

정의

작업이 만들어진 날짜 및 시간을 가져옵니다. Gets the date and time when the job was created.

public:
 property DateTime DateCreated { DateTime get(); };
[Microsoft.SqlServer.Management.Sdk.Sfc.Metadata.SfcProperty(Microsoft.SqlServer.Management.Sdk.Sfc.Metadata.SfcPropertyFlags.Standalone)]
public DateTime DateCreated { get; }
Public ReadOnly Property DateCreated As DateTime
속성 값

작업이 생성된 날짜 및 시간을 지정하는 DateTime 값입니다. A DateTime value that specifies the date and time when the job was created.

예제

다음 코드 예제에서는 새 작업을 만들고 작성 된 날짜를 표시 합니다.The following code example creates a new job and displays the date on which it was created.

C#C#

Server srv = new Server("(local)");  
Job jb = new Job(srv.JobServer, "Test Job");  
jb.Create();  
Console.WriteLine(jb.DateCreated);  

PowerShellPowerShell

$srv = new-object Microsoft.SqlServer.Management.Smo.Server("(local)")  
$jb = new-object Microsoft.SqlServer.Management.Smo.Agent.Job($srv.JobServer, "Test Job")  
$jb.Create()  
Write-Host $jb.DateCreated  

적용 대상