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

  • Home
  • SEARCH
  • 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 8879111
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T19:52:43+00:00 2026-06-14T19:52:43+00:00

I have a CellTable<Price> table = new CellTable<Price>(); . I also have a TextInputCell

  • 0

I have a CellTable<Price> table = new CellTable<Price>();.

I also have a TextInputCell column:

        priceColumn = new Column<Price, String>(new TextInputCell()) {
            public String getValue(Price p) {
                if (p.getPrice() == 0)
                    return "";
                return p.getPrice()+"";
            }   
        };

Also I have a refresh button. If the button is pressed, then it basically reload all data from server and then set the data to the table.

When the table first time load data, it is fine. Let’s say, a cell has price of 12.

Then if I modify that cell to 11 (or whatever value other than 12), then the 11 stays there forever. I mean, even if I press the refresh button, the cell’s data will not change back to 12, but still stay 11.

How can I make the column / cell not remembering the user input?

  • 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-06-14T19:52:45+00:00Added an answer on June 14, 2026 at 7:52 pm

    After you received the new data and updated your objects with the new data call table.redraw();

    Working example

    final Price p1 = new Price(4);
    final Price p2 = new Price(5);
    final Price p3 = new Price(6);
    
    final CellTable<Price> table = new CellTable<Price>();
    
    Column<Price, String> priceColumn = new Column<Price, String>(new TextInputCell()) {
        public String getValue(Price p) {
        if (p.getPrice() == 0)
            return "";
        return p.getPrice() + "";
        }
    };
    
    ListDataProvider<Price> dataProvider = new ListDataProvider<Price>();
    dataProvider.addDataDisplay(table);
    
    List<Price> list = dataProvider.getList();
    list.add(p1);
    list.add(p2);
    list.add(p3);
    
    table.addColumn(priceColumn);
    
    Button b = new Button("refresh");
    b.addClickHandler(new ClickHandler() {
    
        @Override
        public void onClick(ClickEvent event) {
        // your refresh logic, update the items already loaded into the CellTable!
        p2.setPrice(1000);
        p3.setPrice(2000);
    
        table.redraw();
        }
    });
    
    RootPanel.get().add(table);
    RootPanel.get().add(b);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a GWT CellTable<MyType> . This table have rows which should display a
I have a sortable column in a CellTable. The problem is that I have
I have a CellTable with one custom column where I render it manually and
I have 3 column + 10 rows in celltable. value1Column, value2Column, RecordState 1 |
I need a tabbing in celltable. So, I have applied a tabIndex to TextInputCell
I have CellTable with password as one column. I want the password column to
i have a celltable in GWT, I can change color of a specific column
I have a CellTable with a column of TextInputCells. When i set the value
I have this button cell in my CellTable ButtonCell reListCell = new ButtonCell(); reListColumn
I have a celltable which contains numbers in each column. Is there a way

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.