SOLVED How to clear the values of a smartselect?


#1

I can´t clear/remove the selected values in a smartselect that I have, I have looked at the docs but I can´t get it to work, so any input appreciated, thanks.

My select that I have now.

<li>
    <a href="#" class="item-link smart-select smart-select-init" data-open-in="popover">
   
        <select id="fargerna" name="fargerna" class="fargerna" multiple>
          
          <optgroup label="Välj färger.">
          <%do until rs1.eof%>
          <option value="<%=rs1("farg")%>"><%=rs1("farg")%></option>
            <%rs1.movenext
  			loop%>
           
          </optgroup>
         
        </select>
        <div class="item-content item-input" style="padding-left: 0px;">
          <div class="item-inner">
            <div class="item-title">Välj färg</div>
          </div>
        </div>
        </a>
    </li>

#2

http://framework7.io/docs/smart-select.html#smart-select-methods-properties

smartSelect.setValue([])

#3

Thanks Vladimir. Got it working.