> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.carbone.io/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# Insert dynamic images as shapes (rectangle with rounded corners)

# Insert dynamic images as shapes

|||  Supported only for the DOCX and PDF format. If you need images as shapes for ODT or ODS templates, contact the support team on the chat.

## First Solution

 Insert a shape into the document body, then fill it with an image.

### 1. Insert a shape into the document body

Click on the `Insert` tab > `Shapes` > Select the shape you need.

![](https://storage.crisp.chat/users/helpdesk/website/f355e91d7615e000/screenshot-2024-02-12-at-22090_1rb1v2z.png)

### 2. Draw the shape into the document body

To modify the angle radius of rounded rectangles in Microsoft Word, you can utilize the yellow handle located at the top left corner of the shape. Simply drag this yellow handle to adjust the roundness of the corners to your desired angle.

![](https://storage.crisp.chat/users/helpdesk/website/f355e91d7615e000/screenshot-2024-02-12-at-22094_msi9o3.png)

### 3. Fill the shape with an image

Click on the `Shape format` > `Shape fill` more icon > `Pictures...` > Select a picture from your computer, it will be used as placeholder image for Carbone.
The image must be a JPG or PNG format.

![](https://storage.crisp.chat/users/helpdesk/website/f355e91d7615e000/screenshot-2024-02-12-at-22114_nifuue.png)

### 4. Set the Carbone Tag 

To dynamically insert a picture into the document, you need to include a Carbone tag in the alternative text of the shape.
Follow these steps: right-click on the shape, select `View Alt Text...`, and insert the Carbone tag.

![](https://storage.crisp.chat/users/helpdesk/website/f355e91d7615e000/screenshot-2024-02-12-at-22194_n3859m.png)

### 5. Generate the document with Carbone

The picture from your JSON dataset will be incorporated into the template to produce a document.

![Generated DOCX with the french flag as picture](https://storage.crisp.chat/users/helpdesk/website/f355e91d7615e000/screenshot-2024-02-12-at-22233_1iklndo.png)

## Second Solution

Insert an image into the document body, the crop the image as special shape

### 1. insert a picture as PNG or JPEG on the template

The temporary picture will be replaced by the new image coming from the JSON dataset.

![](https://storage.crisp.chat/users/helpdesk/website/f355e91d7615e000/screenshot-2021-07-05-at-16394_uqarxf.png)

### 2. Crop the image to a shape

![](https://storage.crisp.chat/users/helpdesk/website/f355e91d7615e000/screenshot-2021-07-05-at-16400_a77tch.png)

### 3. Insert a Carbone tag in the alternative text of the image

![](https://storage.crisp.chat/users/helpdesk/website/f355e91d7615e000/screenshot-2021-07-05-at-16404_b4jida.png)

### 4. Render the report with Carbone and voilà 🎉

![](https://storage.crisp.chat/users/helpdesk/website/f355e91d7615e000/screenshot-2021-07-05-at-16553_1vloip6.png)