# Void settings() not working

**URL:** <https://discourse.processing.org/t/void-settings-not-working/25542>\
**Category:** Beginners\
**Tags:** homework\
**Created:** [November 19, 2020, 7:33pm UTC](https://discourse.processing.org/t/void-settings-not-working/25542 "2020-11-19T19:33:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ellie98](https://avatars.discourse-cdn.com/v4/letter/e/e47774/32.png) [@Ellie98](https://discourse.processing.org/u/Ellie98)\
**Post date:** [November 19, 2020, 7:33pm UTC](https://discourse.processing.org/t/void-settings-not-working/25542/1 "2020-11-19T19:33:26Z")

</div>

Hello,  
I just typed this code from our script to processing. And the size is staying small, why isn’t it changing?

```auto
public void setup() {
  // Fenstertitel mit aktueller Fenstergröße setzen
  surface.setTitle("Schach " + width + "*" + height);
  background(100);
  
}
//Wenn width und height ungleich sind, wird der größere der beiden Werte in "laenge" gespeichert
void settings(){
 int laenge = 0;
 size(1200,3000);
 size(laenge,laenge);
}
void draw(){

}

```

---

<div class="post-metadata">

**Author:** ![Chrisir](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/chrisir/32/45_2.png) [@Chrisir](https://discourse.processing.org/u/Chrisir)\
**Post date:** [November 19, 2020, 8:02pm UTC](https://discourse.processing.org/t/void-settings-not-working/25542/2 "2020-11-19T20:02:38Z")

</div>

> [@Ellie98](#):
>
> `size(laenge,laenge);`

Laenge is 0, set it to 1000

Chrisir

---

<div class="post-metadata">

**Author:** ![Vako](https://avatars.discourse-cdn.com/v4/letter/v/a9adbd/32.png) [@Vako](https://discourse.processing.org/u/Vako)\
**Post date:** [November 19, 2020, 8:03pm UTC](https://discourse.processing.org/t/void-settings-not-working/25542/3 "2020-11-19T20:03:41Z")

</div>

Settings is used to give the size of the windows with a variable, first of all you should have those variables as global, second

```auto
int laenge = 0;
 size(1200,3000);
 size(laenge,laenge);

```

What you’re doing here is creating a variable with value 0, then you’re changing the size to 1200x3000 and then you’re changing it to 0x0, mind the order in which you write your commands
