Welcome Guest Search | Active Topics | Sign In | Register

DataGrid +client API Options
Felix Weinraub
Posted: Wednesday, September 30, 2009 5:10:20 AM
Rank: Member
Groups: Member

Joined: 1/5/2009
Posts: 27
My platform: asp.net V. 2.0 EO-DataGrid
I have a WebMethod which will return a data set to the client using the ASP.NET AJAX ScriptManager.
Now I need to bind the Grid with the new data on the client side. It is possible to render and redraw the EO-DataGrid with the new data?
eo_support
Posted: Wednesday, September 30, 2009 8:50:36 AM
Rank: Administration
Groups: Administration

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

You won't be able to do that. The Grid supports Callback mode for you to perform such updates, which is similar but is done through server event, not web method.

Thanks!
Felix Weinraub
Posted: Thursday, October 1, 2009 12:53:06 PM
Rank: Member
Groups: Member

Joined: 1/5/2009
Posts: 27
You mean the ICallbackEventHandler Interface?
What about the presentation of the datagrid after refresheing the content?
The datagrid has a fixed number of lines after rendering in code behind.
It may be that the number of rows in the DataGrid changes after Callback; then the presentation can be changed?

Thanks!
eo_support
Posted: Thursday, October 1, 2009 1:09:42 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
No. This is what I meant (look for Callback Mode):

http://doc.essentialobjects.com/library/1/grid/mode.aspx

Thanks
Felix Weinraub
Posted: Wednesday, October 7, 2009 11:21:46 AM
Rank: Member
Groups: Member

Joined: 1/5/2009
Posts: 27
Another question in this connexion:
Is there the possibility to change the size of the datagrid on the client via javascript after rendering the Grid via codebehind? I have found in the client API no evidence.

Something like this does not seem to run:

var grid = eo_GetObject("Grid1");
grid.style.height=275; ->'style' is NULL or no object

I suspect that it is not implemented. Is there another way?

Thanks!
eo_support
Posted: Wednesday, October 7, 2009 12:24:52 PM
Rank: Administration
Groups: Administration

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

I believe you can do:

grid.setSize(w, h);

eo_GetObject returns a JavaScript object, not a DHTML element. So it doesn't have style property. See here for what methods the Grid object has:

http://doc.essentialobjects.com/library/1/jsdoc.public.grid.aspx

Thanks
Felix Weinraub
Posted: Thursday, October 8, 2009 9:30:57 AM
Rank: Member
Groups: Member

Joined: 1/5/2009
Posts: 27
works fine!

how to address other attributes (for example ScrollBars = "Auto" or no ScrollBars) per javascript?
In 'jsdoc.public.grid.aspx' I have found no evidence to.

Thanks!
eo_support
Posted: Thursday, October 8, 2009 9:33:23 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
You can not. That's why the document is useful for you. It tells you what is available and what is not available.

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.