ScriptingOptions 생성자
Initializes a new instance of the ScriptingOptions class.
네임스페이스: Microsoft.SqlServer.Management.Smo
어셈블리: Microsoft.SqlServer.Smo(Microsoft.SqlServer.Smo.dll)
구문
‘선언
Public Sub New
‘사용 방법
Dim instance As New ScriptingOptions()
public ScriptingOptions()
public:
ScriptingOptions()
new : unit -> ScriptingOptions
public function ScriptingOptions()
주의
기본 생성자는 모든 필드를 기본값으로 초기화합니다.
예
The following code example creates a new instance of the ScriptingOptions class and uses it to configure a Scripter.
Visual Basic
Dim srv As Server
srv = New Server
Dim scriptingOptions As ScriptingOptions
scriptingOptions = New ScriptingOptions
scriptingOptions.ScriptDrops = false
scriptingOptions.WithDependencies = true
Dim scrp As Scripter
scrp = New Scripter(srv)
scrp.Options = scriptingOptions
PowerShell
$srv = New-Object Microsoft.SqlServer.Management.Smo.Server("(local)")
$scriptingOptions = New-Object Microsoft.SqlServer.Management.Smo.ScriptingOptions
$scriptingOptions.ScriptDrops = $FALSE
$scriptingOptions.WithDependencies = $TRUE
$scrp = New-Object Microsoft.SqlServer.Management.Smo.Scripter($srv)
$scrp.Options = $scriptingOptions
참고 항목
참조
Microsoft.SqlServer.Management.Smo 네임스페이스