既存のロケーション別名を削除します。
構文
EsbDeleteLocationAlias ( hCtx , AliasName ) ByVal hCtx As Long ByVal AliasName As String
パラメータ | 説明 |
---|---|
hCtx |
APIコンテキスト・ハンドル |
AliasName |
ロケーション別名 |
戻り値
AliasNameという名前が付いたロケーション別名が見つからない場合は、エラーが戻されます。
例
Public Sub LocationAliasTest() Dim status As Long Dim ListCount As Integer Dim Aliases As Variant Dim HostNames As Variant Dim AppNames As Variant Dim DbNames As Variant Dim UserNames As Variant status = EsbCreateLocationAlias(hCtx, "blah1", "LocalHost", "Demo", "Basic", _ "admin", "password") If (status <> 0) Then MsgBox "Create routine Failed" Exit Sub End If status = EsbCreateLocationAlias(hCtx, "blah2", "LocalHost", "Demo", "Basic", _ "admin", "password") If (status <> 0) Then MsgBox "Create routine Failed" Exit Sub End If status = EsbGetLocationAliasList(hCtx, ListCount, Aliases, HostNames, _ AppNames, DbNames, UserNames) If (status <> 0) Then MsgBox "Get routine Failed" Exit Sub End If If (ListCount > 0) Then ' Retrieve the elements as Aliases(0) to Aliases(ListCount -1) End If status = EsbDeleteLocationAlias(hCtx, "blah1") If (status <> 0) Then MsgBox "Delete routine Failed" Exit Sub End If status = EsbGetLocationAliasList(hCtx, ListCount, Aliases, HostNames, _ AppNames, DbNames, UserNames) If (status <> 0) Then MsgBox "Get routine Failed" Exit Sub End If End Sub
関連トピック