---
title: "getContainer Method"
canonical: https://customerscanvas.com/docs/cc6/customerscanvas.iframeapi.objectmodel.printarea.getcontainer.htm
archived: true
applies_to:
  - product: "Customer's Canvas On-Premises"
  - product: "Design Editor"
    versions: ["6.15.0", "6.x (may differ)"]
---

**You’re viewing outdated documentation.** [View the latest Customer’s Canvas On-Premises documentation](https://customerscanvas.com/docs/on-premises/).

# getContainer Method

**Applies to:** Customer's Canvas On-Premises; Design Editor 6.15.0, 6.x (may differ) · **Archived documentation**
 
### Callable
 
- getContainer(name:  string ) :  [Container](https://customerscanvas.com/docs/cc6/customerscanvas.iframeapi.objectmodel.container.htm.md)

- Gets a container by its name.
  
 - example
     - ```
    // Load the editor.
    CustomersCanvas.IframeApi.loadEditor(iframe, productDefinition)
        // If the editor has been successfully loaded.
        .then(function (editor) {
            // When we get the product.
            editor.getProduct().then(function (product) {
                // Display a container with the "foil" name.
                console.log(product.currentSurface.printAreas[0].getContainer("foil"));
            });
        });
    ```

#### Parameters

    - ##### name: string 
  
        A name of the container.

#### Returns Container
