gridview

ASP.NET gridview set to null, but reverts to original selection upon doing an add

I have a "Clear" button which sets the gridview datasource to null and binds it. However, when I add a new entry to it, the old rows seem to show up again (in addition to the new row)...not sure what I am doing wrong.... gv.DataSource = null; gv.DataBind(); Shouldn't the above clear out the state of the gridview? TIA protected voi...

Using DropDownList in EditTemplates of a GridView

I am working on a GridView in Asp.Net. When initially a the Page Loads, my gridview look like: When a user clicks, to edit a row, I am using edit templates to show 'Domain' in a DropDownList. But problem is , when the DropDownlist gets load with data, it lost the current value of the 'Domain'. i.e If I want to edit 4th Row, its domain ...

Invert WPF GridView to bind items to columns instead of rows

Is there a simple way to invert a WPF GridView so that items are bound to columns instead of rows? Or would it be necessary to write a custom view mode? ...

css problem in top:??

i have to fix the header in a gridview and i use this in style Class <style type="text/css"> .gridFixedHeader { background-color:white; position:relative; top:expression(GridView1.offsetParent.scrollTop-2); } </style> but i get an error that expression(GridView1.offsetParent.scrollTop-2);is not valid... what all do i need to do to ma...

Scroll in wizard control when data is more.

Hi, I have a page with wizard controls in it. The wizard's first step contains gridview. When the data in the gridview is more in number, I have to use browser's scrolling button to access "next/previous" buttons. My question is ..can i have a scrollbar inside the wizard...so that "Next/Previous" buttons are always visible. Thanks in ad...

Determine the height of a GridView during data binding.

I need to manually page a GridView based report, i.e. add a second page and GridView, when the height of my first GridView exceeds a limit. Is there a way I can determine the height of the GridView while data binding? ...

import excel data to gridview C#

hi... i need the code for import excel data to gridview in windows forms application... Plz anyone can tell me that code.... ...

How to sort only displayed rows in gridview?

I have a gridview with paging, which displays 5 records in each page. How can I sort the elements of the current page only? And other pages should not be sort? I am using ASP.NET and C#.NET. Is there any way to do this in LINQ? Thank You. ...

Is there an easy way to do a Master Grid View that links to a Detail grid view?

I've been struggling with trying to get this to work. Does anybody know of a easy to follow tutorial that shows the Master/Detail grid view? Thanks. I'm a very novice programmer. I'm using Visual Studio 2008 with c#. ...

Applying a style to a gridview

I have been tearing my hair out all afternoon on this, hopefully someone can help me. Bear with me on this one. I have a number of styles in my App.xaml which transforms a gridview, the code looks like this. <Application.Resources> <Style x:Key="{x:Static GridView.GridViewScrollViewerStyleKey}" TargetType="{x:Type ScrollV...

A few questions about gridviews.

I need to have a grid on one of my webpages that will be used to enter budget information. I was planning on using a gridview, but I am open to other ideas if something else will fit my needs better. I need the following functionality in my grid: All cells are in edit mode as soon as the page loads Need a footer row at the bottom to ...

jQuery IE7 bug on multiple .hide listeners

I'm building a product page, can be seen here (http://n9nemedia.net/v2/products/), and the script in a singular fashion (not hiding multiple divs with one listener works perfect - can be seen here http://www.supercentral.net/downloads by clicking on "Read List" under Zombie Map Pack) works perfectly. My question is, what can I do to ma...

given up on gridview fixed header

Working on: asp.net Gridview Control ok i tried and tried and maybe searched the entire web... but i could not find anything good for my asp.net gridviewcontrolwhich whill fix the header and allow sorting. but most of all work in all browsers and not just IE and Firefox alone.... chrome was the main problem nothing worked... this was on...

How to select particular row in a gridview

I have a Gridview <asp:GridView ID="GridView1" runat="server" Width="400px" AutoGenerateColumns="false" OnSelectedIndexChanged="GridView1_SelectedIndexChanged1"> <Columns> <asp:TemplateField> <ItemTemplate> <asp:CheckBox ID="CheckBox1" runat="server" />...

'View cannot be shared by more than one ListView' Wpf Error

What is wrong with this code ? It throws the Exception: "View cannot be shared by more than one ListView" <ListView ItemsSource="{Binding}" SelectionMode="Extended"> <ListView.Style> <Style TargetType="ListView"> <Style.Triggers> <DataTrigger Binding="{Binding ElementName=MyControl, Path=IsCompany}" Value="True"...

How do I programmatically add a button to a gridview and assign it to a specific code-behind function?

Hey! In runtime I'm creating a DataTable and using nested for-loops to populate the table. This table I later assign as DataSource to a gridview and on RowDataBound I assign the value of each cell. I want to know how I can give each cell a button and assign that button to a codebehind function. I'll have 12 buttons and each one will cont...

Help on C# DevExpress XtraGrid GridControl - making checkbox in cell invisible

I have a GridControl view which is being populated with one column as a Boolean to show the value as a checkbox. However, I wish to hide some checkboxes based on the state of other columns. I have tried to use the gridView_CustomDrawCell() event but cannot find a suitable property. I expected to find a visible property to set to false...

How to align columns in multiple GridViews

How can I get several GridViews on a single page to share the same Column widths? I have four GridViews with (essentially) the same columns in each. They have unique headers and represent data from different queries. I want to maximize readability by allowing the columns to be dynamically sized based on the data but I don't want each ...

How to call in form load the gridview cell click

Hi, I have gridviewname_CellClick(object sender, GridViewCellEventArgs e) event. I want this event to be called in Form load. When i try gridviewname_CellClick(sender,e)- i get exception as e as not an event of GridViewCellEventArgs, how to call this on form load? Any inputs? ...

Making GridView Respond to 2 Drop Down Lists

Hi there. I have got 2 Drop Down Lists on my Form and 1 GridView. I want GridView to display the data according to selection from the Drop Down Lists. For Example, One Drop Down List contains Names and other contains Dates. Both the Drop Down Lists can post back. So if i select a name from 1st Drop Down list, the Grid View should show ...