Welcome Guest Search | Active Topics | Sign In | Register

Binding Grid to datasource Options
rmazza
Posted: Tuesday, April 29, 2008 11:51:57 AM
Rank: Newbie
Groups: Member

Joined: 4/29/2008
Posts: 4
Where can I find sample code as to how to bind the cells in the grid to a database?[code=vb]
eo_support
Posted: Tuesday, April 29, 2008 11:58:05 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,083
Hi,

You can find it from the same source code that you asked in your previous questions. You may also want to go over the documentations, which are available both online and locally as a .chm file.

Thanks
rmazza
Posted: Tuesday, April 29, 2008 12:21:41 PM
Rank: Newbie
Groups: Member

Joined: 4/29/2008
Posts: 4
I see nothing in documentation on how to bind to a database
eo_support
Posted: Tuesday, April 29, 2008 12:44:11 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,083
Hi,

The Grid control is a very data centric control and pretty much every sample that we have fill the Grid from a demo database; And data binding is also mentioned throughout our documentation. So we are not sure how you could have missed it. We can only guess that you didn't look at all. If that is the case, then I am not sure how we can help you further.

I would recommend you to load the sample project with Visual Studio and go over the samples one by one to understand how our product works first --- they should be fairly easy to understand for anyone who has basic ASP.NET knowledge. The documentation also provides a lot of useful information. You should read all the articles under “EO.Web Grid”.

We will be happy to answer your questions if you run into a specific issue during the process ---- but for questions as generic as "how to bind to a database" which is demonstrated pretty much by every sample and also explained through out the documentation, we really do not know how we can explain it better again here.

Thanks
rmazza
Posted: Tuesday, April 29, 2008 12:48:25 PM
Rank: Newbie
Groups: Member

Joined: 4/29/2008
Posts: 4
I see nothing in the documentation that describes how individual columns in the grid are tied to specific fields being returned by a query.
eo_support
Posted: Tuesday, April 29, 2008 12:55:50 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,083
Hi,

Each column has a DataField property that you will need to set:

http://www.essentialobjects.com/ViewDoc.aspx?t=Grid%2fcolumns.html
http://www.essentialobjects.com/ViewDoc.aspx?t=EO.Web.GridColumn.DataField.html

Note data binding for the Grid is a one way process, not both ways, which means changes you made on the client side is not automatically populated back to your data source. If you want to save changes back to your data source, you should rely on a set of server side events mentioned here:

http://www.essentialobjects.com/ViewDoc.aspx?t=Grid%2fediting.html

Hope this helps.

Thanks


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.