how can i change back color of datagrid in wpf when value of one cell is negetive in 2 condition
1:when user insert negetive values
2:when data source is initialized
View Complete Post
I have a WPF 4.0 Datagrid displaying order values and I need to colour the backgroud of the high value orders so the user will notice high value orders easily. Is it possible to set the colour from white to red but increasing in steps say every 10,000 and
increase the colour intensity according to the value.
As this site, http://www.borfin.com.tr/genel/Default.aspx, How can I change the background color selected pages.
Sub DayRender(ByVal source As Object, ByVal e As DayRenderEventArgs)
Dim i As Integer
For i = 0 To DataGrid1.Items.Count - 1
'If (DataGrid1.Items(i).Cells(1).Text = e.Day.Date) Then
'If (DataGrid1.Items(i).Cells(0).Text <> "") Then
If (DataGrid1.Items(i).Cells(1).Text.Equals(e.Day.Date.ToString)) Then
' e.Cell.BackColor = Color.DarkOrange
e.Cell.BackColor = System.Drawing.Color.Red
e.Cell.ForeColor = System.Drawing.Color.Yellow
now I click the day on clendar, which have data from db it chage color , How can I let when the calendar is load wich day have dat in db change color ?
i have a column in the list which has values 1.Added
i want to make the field values Killed to be make it as Red so i tried in sharepoint designer converting to xslt data view then did formatting but the problem is i am not able to see the edit in data sheet option. can you please is there any way i can have
both to be working? or is there any alternate solution for formatting column based on values
thank you so much.
I have a WPF Datagrid binded with list of interface objects.
Consider, ClsEmployee class implements I_Employee interface with properties Empl_Id, Empl_Name, Department, Address and City_name.
consider, _emplList has 10 items.
dgEmployeeGrid.ItemsSource = _emplList;
Now, if the user clicks on a button, then i should be able to read the City_name. Based on the City_name, i should be able to set the color (Color can be different for each row) for the rows dynamically through C# code.
Please help me how to do this?
Thanks in advance!
Hi i am saving color as a string in database
i have a gridview control
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" OnRowUpdating="Update_Schedule"
OnRowDeleting="Delete_Schedule" OnPageIndexChanging="OnPaging" OnRowEditing="Edit_Schedule"
<asp:CheckBox ID="Todo" runat="server" AutoPostBack="true" Height="23px" OnCheckedChanged="CheckedChanged" />
<asp:HiddenField ID="hdn_ScheduleID" runat="server" Value='<%#Eval("ID") %>' />
<asp:Label Text='<%# Eval("Title") %>' runat="server" ID="lbl1"></asp:Label>
I have Used Template Columns in my data grid with each column has its own custom data template with two text boxes .
Now i want to give alternating color to rows but dont know how to do that, as datagrids alternatingrowcolor property gives color to row but it is hidden behidn the datatemplate's textboxes.