About 4,140,000 results
Open links in new tab
  1. java - how to delete one or multiple items from listview using checkbox

    Feb 24, 2019 · I am trying to delete one or multiple items from a listview that is using a custom adapter. I am using the following code below. @Override. public void onClick(View v) { …

  2. How to Use Lists (The Java™ Tutorials > Creating a GUI With …

    In ListDemo, try adding (hiring) and removing (firing) a few items. There are three ways to create a list model: DefaultListModel — everything is pretty much taken care of for you. The …

  3. Remove Multiple Elements from a List in Java - Online Tutorials …

    May 9, 2022 · Learn how to remove multiple elements from a list in Java with this comprehensive guide. Find practical examples and detailed explanations.

  4. Java remove multiple objects from ArrayList

    Feb 18, 2018 · Java removes multiple objects from ArrayList like Remove multiple using List.removeAll method, Remove multiple objects using List.removeIf, Remove multiple objects …

  5. How do I make a list with checkboxes in Java Swing?

    JCheckBox[] newList = new JCheckBox[currentList.getSize() + 1]; for (int i = 0; i < currentList.getSize(); i++) { newList[i] = (JCheckBox) currentList.getElementAt(i); …

  6. java - Remove multiple elements from ArrayList - Stack Overflow

    Feb 9, 2011 · You can remove the elements starting from the largest index downwards, or if you have references to the objects you wish to remove, you can use the removeAll method. you …

  7. java - How can delete listview items using checkbox ... - Stack Overflow

    Nov 14, 2015 · I don't know how can I delete multiple items from listview when I select items in checkbox and click delete button. I am adding a piece of code. ListView lv; ArrayList<x_obj> …

  8. Remove multiple elements with multiple indexes from arraylist in java

    Feb 17, 2019 · Loop thru the indexes you want to delete. Cast Integer to int - remove (int index). Done. Solution using java stream API, Shaunak Patel...thanks a lot for taking time to make it. …

  9. java - Remove certain elements in one list based on condition …

    Feb 28, 2018 · I'm fairly new to Java 8. I have a requirement to subtract/remove POJOs in one list based on certain criteria (from another list) and show it on UI. Iterate one list and search for …

  10. java - How to remove multiple items in JList - Stack Overflow

    May 14, 2016 · DefaultListModel dlm = (DefaultListModel) subjectList.getModel(); if(this.subjectList.getSelectedIndices().length > 0) { int[] selectedIndices = …

Refresh