This page shows how to manage the VAL 3 applications of a Staubli CS8 or CS9 controller from a PC: list them, load a project from the disk of the controller, start it, stop it and unload it. The tasks that an application creates are on the page [VAL 3 tasks](/staubli/documentation/soap-tasks).

## List the applications

`GetValApplications()` returns the VAL 3 applications of the controller.

**C# : ApplicationList**
```csharp
using UnderAutomation.Staubli;
using UnderAutomation.Staubli.Soap.Data;

public class ApplicationList
{
    static void Main()
    {
        var controller = new StaubliController();
        controller.Connect("192.168.0.254");

        /**/
        ValApplication[] applications = controller.Soap.GetValApplications();

        foreach (ValApplication application in applications)
        {
            Console.WriteLine($"{application.Name}: loaded={application.Loaded} running={application.IsRunning} encrypted={application.IsCrypted}");
        }
        /**/

        controller.Disconnect();
    }
}
```

**Python : ApplicationList**
```python
from underautomation.staubli.staubli_controller import StaubliController

controller = StaubliController()
controller.connect("192.168.0.254")

##
applications = controller.soap.get_val_applications()

for application in applications:
    print(
        f"{application.name}: loaded={application.loaded} "
        f"running={application.is_running} encrypted={application.is_crypted}"
    )
##

controller.disconnect()
```

| Property    | Meaning                      |
| ----------- | ---------------------------- |
| `Name`      | Name of the application      |
| `Loaded`    | The application is in memory |
| `IsRunning` | The application runs         |
| `IsCrypted` | The application is encrypted |

## Load and start a project

`LoadProject(path)` loads a project from the disk of the controller, without starting it. `StartApplication(path)` starts it. The path is the one of the project file on the controller, for example `Disk://myProject/myProject.pjx`.

**C# : ApplicationLoadStart**
```csharp
using UnderAutomation.Staubli;

public class ApplicationLoadStart
{
    static void Main()
    {
        var controller = new StaubliController();
        controller.Connect("192.168.0.254");

        /**/
        // Path of the project on the disk of the controller
        string project = "Disk://myProject/myProject.pjx";

        // Load the application in memory, without starting it
        controller.Soap.LoadProject(project);

        // Start it
        controller.Soap.StartApplication(project);
        /**/

        controller.Disconnect();
    }
}
```

**Python : ApplicationLoadStart**
```python
from underautomation.staubli.staubli_controller import StaubliController

controller = StaubliController()
controller.connect("192.168.0.254")

##
# Path of the project on the disk of the controller
project = "Disk://myProject/myProject.pjx"

# Load the application in memory, without starting it
controller.soap.load_project(project)

# Start it
controller.soap.start_application(project)
##

controller.disconnect()
```

When the controller refuses, the method throws a `CustomSoapException`. Its `ErrorCode` tells why, for example `ApplicationNotFound` or `CannotStartApplication`. See [Connect to your robot](/staubli/documentation/connect) for the errors.

## Stop and unload

**C# : ApplicationStop**
```csharp
using UnderAutomation.Staubli;

public class ApplicationStop
{
    static void Main()
    {
        var controller = new StaubliController();
        controller.Connect("192.168.0.254");

        /**/
        // Stop the running application. It stays in memory.
        controller.Soap.StopApplication();

        // Or stop every application and remove them from memory
        controller.Soap.StopAndUnloadAll();
        /**/

        controller.Disconnect();
    }
}
```

**Python : ApplicationStop**
```python
from underautomation.staubli.staubli_controller import StaubliController

controller = StaubliController()
controller.connect("192.168.0.254")

##
# Stop the running application. It stays in memory.
controller.soap.stop_application()

# Or stop every application and remove them from memory
controller.soap.stop_and_unload_all()
##

controller.disconnect()
```

- `StopApplication()` stops the running application. It stays in memory.
- `StopAndUnloadAll()` stops every application and removes them from memory.

A running application can move the arm: check the state of the cell before you start or stop one from a PC.

## Try it in the demo application



## Reference

**Methods of SoapClientBase**
```csharp
// Get all the VAL applications available on the controller
ValApplication[] GetValApplications();

// Load a project in memory from disk (does not start it)
void LoadProject(string projectPath);

// Start a VAL application on the controller
void StartApplication(string applicationPath);

// Stop all VAL applications on the controller
void StopAndUnloadAll();

// Stop application on the controller
void StopApplication();
```

Every method also exists in an asynchronous version, with the same name followed by `Async` and an optional `CancellationToken`.

**Members of Soap.Data.ValApplication**
```csharp
public class ValApplication {
    public ValApplication()

    public override bool Equals(object obj)

    public override int GetHashCode()

    // Indicates whether the application is encrypted.
    public bool IsCrypted { get; set; }

    // Indicates whether the application is currently running.
    public bool IsRunning { get; set; }

    // Indicates whether the application is loaded in memory.
    public bool Loaded { get; set; }

    // Name of the application.
    public string Name { get; set; }

    public override string ToString()
}
```