Object Data Source and Custom Business Object

G

Guest

Dear All,

I am using issue tracker architecture and developed business object for my
application. Now, in VS Beta 2, I humbly want to know how i can have same
feature as dataset, in my business object, what i mean is, if you have
dataset object and assign it to gridview, you can add/edit/delete row
(without affecting table) and then post it back to database. Same thing i
want to have for my business object (which is generic collection) assign to
gridview. So when I add records to my collection it should adds to
mycollection, on delete it should deletes from the collection and on update
it should updates my collection, then on final submit i loop through my
collection and do neccessary updates to my database (like a batch mode).

Why i need it:-
A) I have a child table which gets primary key from the Main table. So, if
my gridview source is Business Object collection, i can save the record in
main table (which is also a custom BO), get the primary key and save the
child table records accordingly.
B) Gridview does not allow insert and Gridview/Detailview will not show
ANYTHING if there is no data and not allow you even to insert. /**** Without
insert how you will get data and without data you cannot insert (What
Microsoft ASP.NET guru want to achieve with this merry-go-round i dont know)
****/.
C) By using custom collection I can add a empty object, so it show me dummy
record in Detailview with default values. Now user can atleast edit it, and
if they have more records they can carry on with insert.

Question:-

1) How in my business object class I will have access to the instance of
Collection class (created on webpage) to manuplate it?

NOTE:
my requirement is to update the data in collection only, WITHOUT affecting
the database. Let say user adds/edits/delete any of records in gridview, it
should only affect the Business Object (Generic Collection), after on final
submit i will update it to the database.

Thanks & any help would be highly appreciated.

Khuzema
www.wisdom.com.kw
 

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,755
Messages
2,569,536
Members
45,014
Latest member
BiancaFix3

Latest Threads

Top