Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6100429
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T13:23:08+00:00 2026-05-23T13:23:08+00:00

So basically my database was working for a little while (very glitchy though, had

  • 0

So basically my database was working for a little while (very glitchy though, had to basically restart my application to see the change in my list view).

This is a two part question:

I use a customized adapter and use

ea.notifyDataSetChanged();

to try and update my adapter. But I think the problem lies that the arrays don’t update as well.

List<String> rList = db.selectAllReceive();
    receiveMessages = rList.toArray(new String[rList.size()]);

Should I just update the array inside the adapter?

Part two:

db.delete(clicked);
        Toast.makeText(getBaseContext(), "Deleted Row: " + clicked, Toast.LENGTH_SHORT);
        Log.i("ContextMenu", "[MainAct.Class] Clicked DELETE");
        ea.notifyDataSetChanged();

This is my code that is within my onContextItemSelected(). I get my log, but I do not get a Toast or notice any database deletion.

Maybe it all comes down to the fact that the array is not updated enough? Should I create a method to update the arrays and use it after it?

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T13:23:09+00:00Added an answer on May 23, 2026 at 1:23 pm

    Without the whole class/classes, hard to say for sure, but I would presume a threading issue. The Toast message not showing up suggests this (I think), I would check into if you’re doing the threading properly for dealing with the database updates and list view updating.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Basically, I have an RPG-type Rails application. I'm storing skills in a skills database
I am working on a Cocoa application which talks to a local SQLite database
I am working with database data that manipulates college students exam results. Basically, I
I'm working on a database schema that's driving me a little mad at the
Basically I am creating a database driven website in Web Developer 2008. The database
Basically I need to connect to the database without any existing databases. In SQL,
Basically I'm converting local dates stored in the database into UTC. But I've read
Basically the program takes customer information and dumps it in a database. In order
Basically, I'm trying to selectively copy a table from one database to another. I
I'm trying to basically do a search through the database with Perl to tell

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.