Re: how to update database, when a row a deleted in the smartGwt ListGrid

2010-07-02 Thread Sean
You have to connect to your server (via RPC for example) and submit a
DELETE query where the row is equal to what was in the listGrid.

On Jul 2, 3:03 am, GWT Groups  wrote:
> Hello Friends...
>
> Now i need your help..
> I am working on SmartGwt Expendable Grid...I am using ListGrid Class
> to generate grid.
> i want to delete the row from the grid...and changes should  reflect
> into my database..Please provide me some idea to do that...
>
> This is my code fragment...
>
> 
>                              ListGrid listGrid = new ListGrid() ;
>
>                             listGrid.setShowRollOverCanvas(true);
>                             listGrid.setWidth(800);
>                             listGrid.setHeight(400);
>
>                             listGrid.setAnimateRollOver(true);
>                             listGrid.setCanExpandRecords(true);
>                             listGrid.setAlternateRecordStyles(true);
>                             listGrid.setShowAllRecords(true);
>                             listGrid.setSelectionType(SelectionStyle.SIMPLE);
>
> listGrid.setSelectionAppearance(SelectionAppearance.CHECKBOX);
>
> listGrid.setExpansionMode(ExpansionMode.DETAIL_FIELD);
>                             listGrid.setDetailField("report");
>
> // on click the remove button i want to delete the selected row from
> the database...
> // using this method "removeSelectedData();" my selected record
> deleted from the grid but not from the database.
>
> removeButton.addClickHandler(new ClickHandler() {
>
>                               public void onClick(ClickEvent event)
> {
>                                         SC.say("Inside Remove Button");
>                                          listGrid.removeSelectedData();
>                                     }
>                             });
>
>  NOTE:- I am directly fetching data from the database and set that
> data into the DataSource. and this datasource is linked with the grid.
>
> ..
>
> Now Please tell me how can i update my database when i delete selected
> record from the SmartGwt List Grid .
>
> I need Help...
> Thanks

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



how to update database, when a row a deleted in the smartGwt ListGrid

2010-07-02 Thread GWT Groups
Hello Friends...

Now i need your help..
I am working on SmartGwt Expendable Grid...I am using ListGrid Class
to generate grid.
i want to delete the row from the grid...and changes should  reflect
into my database..Please provide me some idea to do that...

This is my code fragment...


 ListGrid listGrid = new ListGrid() ;

listGrid.setShowRollOverCanvas(true);
listGrid.setWidth(800);
listGrid.setHeight(400);

listGrid.setAnimateRollOver(true);
listGrid.setCanExpandRecords(true);
listGrid.setAlternateRecordStyles(true);
listGrid.setShowAllRecords(true);
listGrid.setSelectionType(SelectionStyle.SIMPLE);
 
listGrid.setSelectionAppearance(SelectionAppearance.CHECKBOX);
 
listGrid.setExpansionMode(ExpansionMode.DETAIL_FIELD);
listGrid.setDetailField("report");

// on click the remove button i want to delete the selected row from
the database...
// using this method "removeSelectedData();" my selected record
deleted from the grid but not from the database.

removeButton.addClickHandler(new ClickHandler() {

  public void onClick(ClickEvent event)
{
SC.say("Inside Remove Button");
 listGrid.removeSelectedData();
}
});

 NOTE:- I am directly fetching data from the database and set that
data into the DataSource. and this datasource is linked with the grid.

..

Now Please tell me how can i update my database when i delete selected
record from the SmartGwt List Grid .


I need Help...
Thanks

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.