# Missing language/ library?

**URL:** <https://discourse.processing.org/t/missing-language-library/4576>\
**Category:** Coding Questions\
**Created:** [October 17, 2018, 8:01pm UTC](https://discourse.processing.org/t/missing-language-library/4576 "2018-10-17T20:01:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ricodevs](https://avatars.discourse-cdn.com/v4/letter/r/e0b2c6/32.png) [@ricodevs](https://discourse.processing.org/u/ricodevs)\
**Post date:** [October 17, 2018, 8:01pm UTC](https://discourse.processing.org/t/missing-language-library/4576/1 "2018-10-17T20:01:36Z")

</div>

Hey, I tride to copy a code from p5 preferences to make a button. I got some error saying some of the codewords were missing. Im wondering if there is some library or language I’m missing.

```auto
var button

function setup() {
  createCanvas(300,400)
}

function draw() {
  background(155)
  button1 = createButton('1')
  button.position (20,300)
  button.mousePressed(background(255,0,0))
}

```

also, if you know any other ways to make a button, I would be happy to hear about them:)

---

<div class="post-metadata">

**Author:** ![ricodevs](https://avatars.discourse-cdn.com/v4/letter/r/e0b2c6/32.png) [@ricodevs](https://discourse.processing.org/u/ricodevs)\
**Post date:** [October 17, 2018, 8:03pm UTC](https://discourse.processing.org/t/missing-language-library/4576/2 "2018-10-17T20:03:00Z")

</div>

just realized I called the button for button1, but still doesn’t work…

---

<div class="post-metadata">

**Author:** ![jeonghopark](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/jeonghopark/32/1986_2.png) [@jeonghopark](https://discourse.processing.org/u/jeonghopark)\
**Post date:** [October 17, 2018, 8:56pm UTC](https://discourse.processing.org/t/missing-language-library/4576/3 "2018-10-17T20:56:01Z")

</div>

hi, createButton needs Dom library.

```auto
<script type="text/javascript" src="p5.dom.js"></script>

```

and for button.mousePressed()  
[https://p5js.org/reference/#/p5.Element/mousePressed](https://p5js.org/reference/#/p5.Element/mousePressed)

or something like

```auto
button.mousePressed(backgroundChange);

function backgroundChange() {
   ...
}

```
