I used to have a class in 1.1 for the Datagrid that inherited from the DataGridColumn class. This allowed me to create a check box column with a client-side un/check-all box in the header. Then as I designed my grid I would just add my custom column.
I am currently on a project where I need similar functionality for the grid view, howev...
I have a GridView control that I am dynamically creating at runtime. I am creating all the columns like this.
foreach (GridColumnConfig column in columns)
{
BoundField boundField = new BoundField();
boundField.HeaderText = column.Title;
boundField.DataField = column.FieldName;
boundField.SortExpression = column.FieldName...
Hi !
I have a gridview and I need to sort its elements when the user clicks on the header.
Its datasource is a List object.
The aspx is defined this way :
<asp:GridView ID="grdHeader" AllowSorting="true" AllowPaging="false"
AutoGenerateColumns="false" Width="780" runat="server" OnSorting="grdHeader_OnSort...
I have a very simple ASP.Net page that acts as a front end for a stored procedure. It just runs the procedure and shows the output using a gridview control: less than 40 lines of total code, including aspx markup. The stored procedure itself is very... volatile. It's used for a number of purposes and the output format changes regularl...
I've got a small web form with 2 radio buttons, call them PickFromList and EnterValue. When PickFromList is checked I want to show a GridView that I've configured to bind to an ObjectDataSource. When EnterValue is checked I want the GridView to disappear.
This form is laid out using a table and want to hide/show the appropriate rows b...
My problem is that all the textbox's my formview are getting cleared when I hit the submit button.
I currently have a page with a small section that has an update panel around it. This small section adds an address to my databse. To the left of this form there is a gridview that is tied into the formview. So if i click on an item in the...
How can I use Hyperlink button in gridview. I mean when I run my program,all data is displayed in gridview,but I want hyperlink in gridview, so that when I will click in hyperlink it will show the select path which is in gridview : if there is pdf file path and I just click on this hyper link then I can see the pdf file.
Can you tell me...
I need a grid that will allow me to freeze a column (the Ms Excel style). I do not need to freeze rows.
Of course the Asp.net 2.o Gridview does not supports this out of the box.
I am sure someone has had a similar requirement and had a way foward.
Please advise any options available with the Gridview. I am also open to using any third...
I am working on a co-workers website, and he mistakenly put up a gridview that shows a TypeID instead of the TypeName. I want to put the actual NAME of the type, instead of it's arbitrary ID number, like he has it. I see he has two "ObjectDataSource"'s on the page -- one for Type and one for Item. Items contains the ID of what TYPE th...
I have a GridView defined like this:
<asp:GridView ID="myGridView" ruant="server">
<asp:BoundField DataField="myField" />
<asp:CommandField ShowDeleteButton="true" ShowEditButton="true" />
</asp:GridView>
After I put a row into edit mode with the Edit button, how do I capture the Enter key and trigger the resulting Update on t...
I have a very standard Gridview, with Edit and Delete buttons auto-generated.
It is bound to a tableadapter which is linked to my "RelationshipTypes" table.
dbo.RelationshipTypes:
ID, Name, OriginConfigTypeID, DestinationConfigTypeID
I wish to use a label that will pull the name from the ConfigTypes table, using the "OriginConfigTypeID...
I have a problem with Gridview sorting that is similar to others but I'm binding to a collection object as opposed to a data table.
The existing business rules and data access layers of an application follow the pattern of having an object and, if you need a collection of objects of that type, to have another class inheriting Collection...
I have seen some gridview header freezing examples on the web but I have a special case where the gridview is in a fixed width div. The examples I tried make the header fixed but the full width of the header is shown and it overflows out of the div while the grid body has a horizontal scroll bar.
I need it to:
1- Header and tbody scroll...
"Both DataSource and DataSourceID are defined on 'grdCommunication'. Remove one definition."
I just got this error today, the code has been working until this afternoon I published the latest version to our server and it broke with that error both locally and on the server. I don't use "DataSourceID", the application reads database qu...
I have an object that returns an IList which I'm getting from my ObjectDataSource and binding to a Gridview. All works fine if I just use standard binding, but I'm trying to customize my binding to set properties on a linkbutton as follows:
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)
{
...
I'm binding a datatable to a gridview control, and when I format each column I need to format the data based on whether that column has a particular custom attribute. In this case, a column can represent:
a text box (in which case I just display the text from the textbox in the gridview),
a checkbox (in which case I display "Checked" ...
The CSS Friendly Control Adapters for ASP.NET are great for creating markup that is easy to style. A big benefit of the GridView adapter is that it generates THEAD, TBODY, and TFOOT tags, which allow you to do some really great things with libraries like jQuery - for instance, Tablesorter for client-side table sorting.
The problem is t...
I've got a list of items in an order to show in asp.net -- each item (row) will have 3 textboxes so the user can both view and change that piece of data (shipping cost, handling cost, price).
What would be one "recommended" way to accomplish this? With a repeater, I assume I'd then have to loop through the form values on postback, and ...
I place the following statements in the second row of my grid in the xaml:
<ScrollViewer VerticalScrollBarVisibility="Auto" Grid.Row="1">
<ListView Name="listView" Margin="5" Grid.Row="1">
<ListView.View>
<GridView AllowsColumnReorder="True">
<GridViewColumn DisplayMember...
I am trying to do something in VisualWebDev 2008 Express that I thought would be simple, but it is not working. I want to display data from an XML file so I added the XMLDataSource to my page, pointed it to the XML file, and then added the GridView and connected it to the datasource. I am getting the following error:
GridView - GridView1...