# setParameterbyName

**URL:** <https://qa.fmod.com/t/setparameterbyname/15128>\
**Category:** Unity\
**Created:** [October 12, 2019, 12:55pm UTC](https://qa.fmod.com/t/setparameterbyname/15128 "2019-10-12T12:55:13Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Omega\_SD](https://avatars.discourse-cdn.com/v4/letter/o/bbce88/32.png) [@Omega\_SD](https://qa.fmod.com/u/Omega_SD)\
**Post date:** [October 12, 2019, 12:55pm UTC](https://qa.fmod.com/t/setparameterbyname/15128/1 "2019-10-12T12:55:13Z")

</div>

Hello guys i have this script  
using System.Collections;  
using System.Collections.Generic;  
using UnityEngine;  
using UnityEngine.UI;

public class m : MonoBehaviour  
{  
[FMODUnity.EventRef]  
FMOD.Studio.EventInstance Menu;  
private string menus = “event:/Menu”;  
private int pa = 0;  
void Start()  
{  
Menu = FMODUnity.RuntimeManager.CreateInstance(“event:/Menu”);  
Menu.start();  
FMODUnity.RuntimeManager.AttachInstanceToGameObject(Menu, GetComponent(), GetComponent());  
}  
public void btnTest (Button btn)  
{  
pa = 1;  
}

```
void Update()
{
   if (pa == 1){

 Menu.setParameterByName("Filter", 1f);
    
}

```

}  
}

Everything is ok except the setParameterByName  
i have this error  
“EventInstance’ does not contain a definition for ‘setParameterByName’ and no accessible extension method ‘setParameterByName’ accepting a first argument of type ‘EventInstance’ could be found”

---

<div class="post-metadata">

**Author:** ![cameron-fmod](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/cameron-fmod/32/261_2.png) [@cameron-fmod](https://qa.fmod.com/u/cameron-fmod)\
**Post date:** [October 16, 2019, 4:34am UTC](https://qa.fmod.com/t/setparameterbyname/15128/2 "2019-10-16T04:34:24Z")

</div>

What version of FMOD for Unity are you using?

---

<div class="post-metadata">

**Author:** ![Omega\_SD](https://avatars.discourse-cdn.com/v4/letter/o/bbce88/32.png) [@Omega\_SD](https://qa.fmod.com/u/Omega_SD)\
**Post date:** [October 16, 2019, 2:15pm UTC](https://qa.fmod.com/t/setparameterbyname/15128/3 "2019-10-16T14:15:52Z")

</div>

i solved it it’s ok  
(fmpd2.0)
