Showing posts with label grid. Show all posts
Showing posts with label grid. Show all posts

Monday, March 26, 2012

Windows forms like Grid

Hello,

I have been working on converting a windows app to web app. Windows app has nice grid where users can enter data or edit by just clicking on the column.

For web environment, I tried to use gridview/detailsview but it requires users to click on update or insert button. Is there something built-in or AJAX based or any solution (not too costly) that provides windows like grid in asp.net 2.0?


Thanks,

VP

None that I can think of.

Thanks for giving details about the implementations. Though is seems like a lot of form elements making it heavy during postbacks. Has anybody done what you are suggestions or something similar? It would be great to get hands on it.

Here's what I might end up buying:

dhtmlxgrid

or codethatgrid

Thanks,

vp


Ofcourse there is a solution for that :-)

With just some creativity, you can create something like that, with a gridview and Ajax.

One direction to create a direct click grid, is to put the gridview in a updatepanel.
After that put a linkbutton in every cell to hold your data.
Attach a edit row_command to the linkbutton .
Use some css to have the linkbutton a 100% (cell) height and width.

In the codebehind of the row_command event, you can easily track the cell that is clicked.
You can even use the row databound event to open a textbox in the clicked cell , or someting like that.

Marchu


Hello,

You are right about the heavy postback, ± 50 rows with 32 cells make a 730 kb page. (in my case)
What i do is, when i change 1 cell, i change this cell directly in the grid, so i dont have to load the full data again. (only Ajax must draw the grid again, what take some time...5secs)

It is not a perfect solutions this, but i been looking and experimenting for a better one.
If i found one, i will post it here.

Marchu


I decided to go withdHTMLxGrid which seems to meet my needs.

I can add data to the grid from code-behing by emitting javascript and then read data back using javascript and copying data to a hidden text field in CSV format which I grab on postbacks. This is the only grid I found which has cell + rows tabbing and allows editing cells without needing any extra keystrokes.

Standard version is free and pro is $150

Thanks for your responses


vp

Saturday, March 24, 2012

working with dataset using asp.net ajax 1.0

I have a web service which is returning a dataset ... this dataset will be bound to a data grid inside an update panel.

How can I get that dataset to the data grid IF the web service is being called via java script ?

Am trying to avoid getting back XML as that would mean a lot of DOM parsing and I dont want to use the DOM structure unless abs necessary ?

If the webservice is being called using javascript, I assume it is on the clientside.

But the binding to the data grid will have to be done on the server.

One way to go is to call the webservice on the server and bind the returned dataset to the datagrid.


Hi,

Maybe this article is helpful to you:http://dotnetslackers.com/articles/ajax/ASPNETAjaxGridAndPager.aspx

Best Regards

Wrapping a custom control for AJAX

I have a custom control the renders a list/grid based on a specialized datasource. All of the heavy lifting is done in OnRender, where I use the HtmlTextWriter to output raw html. I do this because the nature of the containing pages dictates that I render as late and as efficiently as possible. I have implemented this control in a large number of areas across several applications.

Now I am interested in upgrading those applications to use the ASP.NET AJAX framework. The problem is, none of my custom list controls behaves properly inside an UpdatePanel. I believe this is because the controls are rendered late and rendered as straight HTML.

My question is: What are my options on getting this control to behave itself? Obviously the "re-write the control" route is my last option (not because of the time to rewrite, but because of the time to regression test hundreds of implementations of the control). Is there an elegant way to wrap or subtly modify the control such that containers won't necessarily know that it has changed, and still have it perform client-side post backs and in-place updates? I'm open to all suggestions. I'm not a neophyte on this stuff; I've been using the XMLHttpRequest object to do in-place updates for years. But this one has me a little stymied on the practicality of a solution.

I appreciate any help.

Thanks,

Jason

My only solution for you is using the XMLHttpRequest object to do updates:(

I'll think about it tomorrow,Maybe I can provide you with a better solution.

Thanks