# Set same legend for multiple views once

**URL:** https://discourse.paraview.org/t/set-same-legend-for-multiple-views-once/5450
**Category:** ParaView Support
**Tags:** vtk
**Created:** [September 29, 2020, 1:30pm UTC](https://discourse.paraview.org/t/set-same-legend-for-multiple-views-once/5450 "2020-09-29T13:30:42Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![bergt](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/b/74df32/32.png) [@bergt](https://discourse.paraview.org/u/bergt)
#### Post date: [September 29, 2020, 1:30pm UTC](https://discourse.paraview.org/t/set-same-legend-for-multiple-views-once/5450/1 "2020-09-29T13:30:42Z")

</div>

Hi,

My problem is that I have a lot of outputs (actually a set of outputs (time serie)) and I want to know if there is a easy way to set the limits and style to the legend for all outputs at once?

 ![image](https://discourse.paraview.org/uploads/default/original/2X/b/ba75de635eb005e2e3c1eea9dbd9aaf557ac7581.png)

I know how to do it per output but it takes forever to do that and if I close the program an re-opens it all settings are gone ☹

I attach my vtk-file.

[heat.vtk](https://discourse.paraview.org/uploads/short-url/o7dCGkLxVqHUsjdXRkGOg4mA5Qo.vtk) (3.3 MB)

Hoping for a helpful advise 🙂

Best regards  
/tobias

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [September 29, 2020, 2:23pm UTC](https://discourse.paraview.org/t/set-same-legend-for-multiple-views-once/5450/2 "2020-09-29T14:23:36Z")

</div>

Use the SaveSettings button below.  
 ![2020-09-29-232305_531x144_scrot](https://discourse.paraview.org/uploads/default/original/2X/f/f50fa85825c19b698382d4d33c23f86ec9d1c952.png)

---

<div class="post-metadata">

### Author: ![bergt](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/b/74df32/32.png) [@bergt](https://discourse.paraview.org/u/bergt)
#### Post date: [September 29, 2020, 5:03pm UTC](https://discourse.paraview.org/t/set-same-legend-for-multiple-views-once/5450/3 "2020-09-29T17:03:32Z")

</div>

Thank you!  
Best regards  
Tobias

Den tis 29 sep. 2020 16:23Mathieu Westphal (Kitware) via ParaView \<[noreply@discourse.paraview.org](mailto:noreply@discourse.paraview.org)\> skrev:

---

<div class="post-metadata">

### Author: ![bergt](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/b/74df32/32.png) [@bergt](https://discourse.paraview.org/u/bergt)
#### Post date: [September 30, 2020, 4:51am UTC](https://discourse.paraview.org/t/set-same-legend-for-multiple-views-once/5450/4 "2020-09-30T04:51:28Z")

</div>

Hi @mwestphal  
I manage to get the same type of legend for all output but I can’t figure out how to set a range for all output at once?

![image](https://discourse.paraview.org/uploads/default/original/2X/3/3ebb6fb094a6515daed0b50a770451aa3c608a2a.png)

Best regards  
/tobias

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [September 30, 2020, 8:25am UTC](https://discourse.paraview.org/t/set-same-legend-for-multiple-views-once/5450/5 "2020-09-30T08:25:37Z")

</div>

Afaik, this is not supported. I’d suggest transforming your file into a time series instead.

---

<div class="post-metadata">

### Author: ![bergt](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/b/74df32/32.png) [@bergt](https://discourse.paraview.org/u/bergt)
#### Post date: [September 30, 2020, 8:52am UTC](https://discourse.paraview.org/t/set-same-legend-for-multiple-views-once/5450/6 "2020-09-30T08:52:43Z")

</div>

I have thought about that… are there any examples on how to do that?  
Best regards  
/tobias

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [September 30, 2020, 9:20am UTC](https://discourse.paraview.org/t/set-same-legend-for-multiple-views-once/5450/7 "2020-09-30T09:20:10Z")

</div>

I’d write a python script for that. Add a calculator, then something like:

```
for (i in range(120)):
  str = "{:05d}".format(i)
  calculator.Function = "t"+ str
  UpdatePipeline()
  SaveData("/home/glow/data/tmp/aka/heat" + str + ".vtu')

```

This was not tested though.

---

<div class="post-metadata">

### Author: ![bergt](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/b/74df32/32.png) [@bergt](https://discourse.paraview.org/u/bergt)
#### Post date: [September 30, 2020, 9:34am UTC](https://discourse.paraview.org/t/set-same-legend-for-multiple-views-once/5450/8 "2020-09-30T09:34:50Z")

</div>

Thanx! I’ll try that!  
Best regards  
/tobias
