Compartir a través de


Application.RemoveFromSqlServer(String, String, String, String) Método

Definición

Quita un paquete de la instancia especificada de SQL Server.

public:
 void RemoveFromSqlServer(System::String ^ packagePath, System::String ^ serverName, System::String ^ serverUserName, System::String ^ serverPassword);
public void RemoveFromSqlServer (string packagePath, string serverName, string serverUserName, string serverPassword);
member this.RemoveFromSqlServer : string * string * string * string -> unit
Public Sub RemoveFromSqlServer (packagePath As String, serverName As String, serverUserName As String, serverPassword As String)

Parámetros

packagePath
String

Nombre del paquete que se va a quitar.

serverName
String

Nombre de la instancia de SQL Server.

serverUserName
String

El nombre de usuario que se va a usar al autenticarse con el servidor.

serverPassword
String

La contraseña asociada a la cuenta serverUserName.

Ejemplos

En el ejemplo de código siguiente se quita un paquete denominado myNewName que se guardó anteriormente.

static void Main(string[] args)  
{  
    Application app = new Application();  
    // The package was previously saved using this method call.  
    //app.SaveToSqlServerAs(p1, null, "myNewName", "yourserver", null, null);  

    // Remove the previously saved package.  
    app.RemoveFromSqlServer("myNewName", "yourserver", null, null);  
}  
Shared  Sub Main(ByVal args() As String)  
    Dim app As Application =  New Application()   
    ' The package was previously saved using this method call.  
    'app.SaveToSqlServerAs(p1, null, "myNewName", "yourserver", null, null);  

    ' Remove the previously saved package.  
    app.RemoveFromSqlServer("myNewName", "yourserver", Nothing, Nothing)  
End Sub  

Se aplica a