Cool with someone that tries to use state! Have you created the state?
To clear a field you need to call the clear method :
field.clear(); //your example is missing the () which means the function will not be called
The clear method returns a promise, which resolves when QIX engine replies to the call. If you want to have control over the order of the calls (and you probably do) you need to wait for the clear before making the selection, like this:
Hope this helps
Erik Wetterberg https://extendingqlik.upper88.com/