Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bootstrap Dropdown doesn't work programmatically #216

Open
interwap opened this issue Apr 20, 2018 · 0 comments
Open

Bootstrap Dropdown doesn't work programmatically #216

interwap opened this issue Apr 20, 2018 · 0 comments

Comments

@interwap
Copy link

interwap commented Apr 20, 2018

I'm trying to attach a dropdown to an activity programmatically but it just doesnt work. The bootstrap edit text works fine but the dropdown crashes everytime. I have even had to switch versions just to try and get it to work but it doesnt.

BootstrapDropDown bootstrapDropDown = new BootstrapDropDown( this.context ); bootstrapDropDown.setDropdownData( values ); parent.addView( bootstrapDropDown );

where values is a string array. I get hit with this error android.content.res.Resources$NotFoundException: String array resource ID #0xffffffff.

I even add a string array to my strings.xml values event that didnt work using resources. Anyone had luck with this?

<string-array name="bootstap_dropdown_example_data">
        <item>Physical Injuries</item>
        <item>Pollution</item>
    </string-array>
@interwap interwap changed the title Bootstrap Dropdown doesn work programmatically Bootstrap Dropdown doesn't work programmatically Apr 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant