datagrid

C# datagrid click position

Hi, Does anybody know how can I determine where the user clicked in a DataGrid control ? I'm using .NET CF with Windows Mobile 6. What I need to know is whether the user clicked on the selected cell or on an empty area (not covered by columns or rows). Is there a way to retrieve it from EventArgs ? Thanks. ...

How to implement paging for datagrid using LINQ to Entities in wpf?

I'm new in wpf. My main problem is to understand how DataGrid works with its datacontext. It would help me a lot because I don't know how to make a universal paging usercontrol for all my datagrids in the projects for different database tables. DataGrid converts received DataContext from object to some kind of list. How it is implemented...

Disable selecting in WPF DataGrid

How can I disable selecting in a WPFTooklit's DataGrid? I tried modifying the solution that works for ListView (from http://stackoverflow.com/questions/1051215/wpf-listview-turn-off-selection#comment-863179), but that doesn't work: <tk:DataGrid> <tk:DataGrid.ItemContainerStyle> <Style TargetType="{x:Type tk:DataGridRow}"> ...

Flex 4 DataGrid in MDIWindow(flexlib)

Hi! I want to add DataGrid into MDIWindow which is in flexlib. The DataGrid is created in a module and using addChild() function add to a MDIWindow. This MDIWindow is called maximize() after windowManager.add(). I tried to set width of column but when it become maximize the width changes. I've no idea how to set width. Could you give me...

How to access an array collection that within another?

Example, I have the field named city in the Customers table, and a table named cities I attach the table values town in the city, namely: city id = 15 sao paulo to cities It aims to do this, pulling the two array collection and then working in action script and putting the datagrid? Thanks in advance, ha days looking for the solution....

How to return focus from GridView or DataGrid to other control on the page

I Want to know how to focus to control after completing tab navigation for the grid view. I have certain controls in my page and GridView/DataGrid as last control, when I navigate (Tab key navigation) on my page. I can navigate from first control to GridView but when I finish all editable items in grid the tab control goes to browser ad...

WPF DataGrid: Make cells readonly

I use the following DataGrid <DataGrid Grid.Row="1" Grid.Column="1" Name="Grid" ItemsSource="{Binding}" AutoGenerateColumns="False" > <DataGrid.Columns> <DataGridTextColumn Header="Name" Width="100" Binding="{Binding Path=Name}"></DataGridTextColumn> <DataGridTextColumn Header="OldValue" Widt...

DataGrid Column names don't seem to be binding

Sort of a Flex newbie here so bear with me. I've got a DataGrid defined as follows: <mx:Script> ... private function getColumns(names:ArrayCollection):Array { var ret:Array = new Array(); for each (var name:String in names) { var column:DataGridColumn = new DataGridColumn(name); ret.push(column); } retur...

Flex DataGrid mouseover row with gradient background

I have a DataGrid that needs to show a gradient background on mouseover of the row. I have created itemrenderers for each of the columns and the gradient shows up for the individual cell that is moused over, but not for the whole row. How do I get the whole row to show the gradient when mousing over one of the cells? ...

How can I change the visibility of elements inside a DataTemplate when a row is selected in a Silverlight datagrid?

I'm using the MVVM pattern. I've bound my items and I want to only show the edit button when a row is selected in the datagrid. It appears to be possible with triggers in WPF but we don't have triggers in Silverlight. I tried a TemplatedParent binding but I'm not sure what the TemplatedParent is in this case. We don't have RelativeSource...

Flex - Issues vertically aligning Datagrid header text

Hi!! I'm having some issues aligning the header text of a datagrid. I'm using an embed font for the header text, and when applying the css, the header text behaves as if I'd set the text vertical align to top. I'm trying to vertically center the text, but haven't found a way to make it work. An image to give you a better idea: Any ti...

How to turn Flex MXML DataGrid into something like Horisontal DataGrid? (see an Image)

from this (normal dataGrid) into this (horisontal data grid) How to turn Flex MXML DataGrid into something like Horisontal DataGrid? (may be some how with Flash builder 4?) Keeping all stuff DataGrid has like eating data from data provider sortind dragging - droping items etc ...

How to bind a table in a dataset to a WPF datagrid in C# and XAML

I have been searching to hours for something very simple: bind a WPF datagrid to a datatable in order to see the columns at design-time. I can’t get any of the examples to work for me. Here is the C# code to populate the datatable InfoWork inside the dataset info: info = new Info(); InfoTableAdapters.InfoWorkTableAdapter adapter = new ...

Get content of a single cells labelFunction from a DataGrid in Flex 3

This is similar to this question I asked last week. My dataGrid is populated with three phone numbers per row. Each phone number is pulled from an array and displayed using a labelFunction, while the name and description come from the dataProvider. I used the really helpful solution to my last question with some success, but can't grab ...

bind a WPF datagrid to a datatable

I have used the marvelous example posted at: http://www.codeproject.com/KB/WPF/WPFDataGridExamples.aspx to bind a WPF datagrid to a datatable. The source code below compiles fine; it even runs and displays the contents of the InfoWork datatable in the wpf datagrid. Hooray! But the WPF page with the datagrid will not display in the des...

Flex ByteArray data field

The data provider (ArrayCollection) for my data grid consists of objects with ByteArray (int) fields. How do I make the data field display as int without transforming my data provider? ...

WPF - Getting the value of one a DataGridCell from within DataTemplateSelector

Hi, I'm using DataTemplateSelector with the WPFToolkit DataGrid. I want to select the editing template for one cell based on the value of another cell on the same row. The DataTemplateSelector's SelectTemplate method takes two arguments: one is the data item displayed by the grid row, the other is the grid cell. What I want to know is...

right click on grid row

hi to all of you, problem is , that whenever the grid's row is right clicked the selected item is null.how do i make a the grid's row selected when any row was right clicked? thanks Jamal ...

WPF Drag and drop to Datagrid

Hi. I have been searching the internet high and low but can find some examples that can help me, I'm developing an application in wpf, in it I use a datagrid, each cell as a datatemplate with and image, in a mosaic style, on the side of the grid I have some tiles to use on the grid, I'm able to drag the tiles but can't drop then on the g...

DataGridCheckBoxColumn immediate binding

Hi. I'm using the WPF Toolkit Datagrid and have one column which is a DataGridCheckBoxColumn bound to a bool property on my ViewModel. My problem is that I wan't the property to get it's value updated immediately when the user checks or unchecks the checkbox. Now you have to navigate away from the cell in order to have the property up...