Refreshing datagrid

R

Ruby

Hi all...
I have an asp page with a datagrid, and a imagebutton to add a new row.
every time I click that new button, a new page appear and user can entry
data, save and close that page.
the problem is :
I want my datagrid reflecting the changes of my add new row, so every time I
save and close that add new record page,
automatically it add a new row in my datagrid

thank

ruby
 
M

Michael

Just call the .DataBind() method of the datagrid in the page you want to
display the new data. Your datasource will have to be updated with the new
info though. If your datasource is a dataset, this should be pretty easy
and not involve going back to the database and requerying.
 
Q

QUASAR

Why you don't use the same page to add the record directly to the datagrid?
If this can be ok for you the ASP.NET WebMatrix has a good example for this
in the new file template named "editable
data grid" that come with the program...
There also is another my post of today where I have also attached the
file...

Byez,
Quasar
 
R

Ruby Yanto

Thank for advice, I also figured out that method, but the problem is, if
I want to see records that i've entered at the same time i must open
another browser to search for a spesific record

Thank
Ruby
 
R

Ruby Yanto

In What event should I put databind() method, since I don't know exactly
what event will trigger when I close that add new record page

thank

Ruby
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top