{"action":"created","issue":{"url":"https://api.github.com/repos/silviomoreto/bootstrap-select/issues/1167","labels_url":"https://api.github.com/repos/silviomoreto/bootstrap-select/issues/1167/labels{/name}","comments_url":"https://api.github.com/repos/silviomoreto/bootstrap-select/issues/1167/comments","events_url":"https://api.github.com/repos/silviomoreto/bootstrap-select/issues/1167/events","html_url":"https://github.com/silviomoreto/bootstrap-select/issues/1167","id":109572676,"number":1167,"title":"Setting `val` doesn't work","user":{"login":"shaneparsons","id":5495493,"avatar_url":"https://avatars.githubusercontent.com/u/5495493?v=3","gravatar_id":"","url":"https://api.github.com/users/shaneparsons","html_url":"https://github.com/shaneparsons","followers_url":"https://api.github.com/users/shaneparsons/followers","following_url":"https://api.github.com/users/shaneparsons/following{/other_user}","gists_url":"https://api.github.com/users/shaneparsons/gists{/gist_id}","starred_url":"https://api.github.com/users/shaneparsons/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shaneparsons/subscriptions","organizations_url":"https://api.github.com/users/shaneparsons/orgs","repos_url":"https://api.github.com/users/shaneparsons/repos","events_url":"https://api.github.com/users/shaneparsons/events{/privacy}","received_events_url":"https://api.github.com/users/shaneparsons/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-10-02T21:09:54Z","updated_at":"2015-12-23T00:44:08Z","closed_at":null,"body":"Using the following `$('.selectpicker').selectpicker('val', '1');` to preset the value of my select is returning the following error.\r\n\r\n`Uncaught TypeError: e.stopPropagation is not a function`\r\n\r\nThe error is pointing to line 258 in bootstrap-select.js if it helps.\r\ni.e.\r\n```\r\nif (e) {\r\n    e.stopPropagation();\r\n    e.preventDefault();\r\n}\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/silviomoreto/bootstrap-select/issues/comments/166769427","html_url":"https://github.com/silviomoreto/bootstrap-select/issues/1167#issuecomment-166769427","issue_url":"https://api.github.com/repos/silviomoreto/bootstrap-select/issues/1167","id":166769427,"user":{"login":"goyatparmod","id":13874876,"avatar_url":"https://avatars.githubusercontent.com/u/13874876?v=3","gravatar_id":"","url":"https://api.github.com/users/goyatparmod","html_url":"https://github.com/goyatparmod","followers_url":"https://api.github.com/users/goyatparmod/followers","following_url":"https://api.github.com/users/goyatparmod/following{/other_user}","gists_url":"https://api.github.com/users/goyatparmod/gists{/gist_id}","starred_url":"https://api.github.com/users/goyatparmod/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/goyatparmod/subscriptions","organizations_url":"https://api.github.com/users/goyatparmod/orgs","repos_url":"https://api.github.com/users/goyatparmod/repos","events_url":"https://api.github.com/users/goyatparmod/events{/privacy}","received_events_url":"https://api.github.com/users/goyatparmod/received_events","type":"User","site_admin":false},"created_at":"2015-12-23T00:44:08Z","updated_at":"2015-12-23T00:44:08Z","body":"I have same issue seems .val() not working for me as well.I am using ng-repeat in HTML and i tried following options nothing works. Appreciate any help.\r\n\r\n$('#state-search').selectpicker('selectAll');\r\n$state-search.selectpicker(\"val\",$scope.states[0]);\r\n$('#state-search').selectpicker(\"val\",'Utah');\r\n $('#state-search').selectpicker('refresh');\r\n\r\n"}}