In MVVM, how to scroll to the previously selected GanttTask when I update whole ObservableCollection gantt tasks?
Thanks,
-Jacky
Hi to all,
I would avoid that user click single item of group.
Sequence to reproduce behaviour:
I would that step no. 4 did not have any effect.
To highlight selected items, I have write code into SelectionChanged event, where I change background and foreground of selected item.
01.
private
void
topRadDiagram_SelectionChanged(
object
sender, SelectionChangedEventArgs e)
02.
{
03.
//Deselezione degli oggetti
04.
foreach
(var item
in
e.RemovedItems)
05.
{
06.
if
(item
is
RadDiagramShape deselectedItem)
07.
{
08.
deselectedItem.Background = ColorHelper.IMBALLO;
09.
deselectedItem.Foreground = ColorHelper.IMBALLO_TITLE;
10.
11.
//Aggiorna il 3D
12.
var macchina = (ModelloCommerciale)deselectedItem.Tag;
13.
var macchina3D = macchina.Oggetto3D;
14.
macchina3D.Material =
new
DiffuseMaterial(ColorHelper.IMBALLO_TRASPARENTE);
15.
macchina3D.BackMaterial =
new
DiffuseMaterial(ColorHelper.IMBALLO_TRASPARENTE);
16.
}
17.
}
18.
19.
//Selezione degli oggetti
20.
foreach
(var item
in
e.AddedItems)
21.
{
22.
if
(item
is
RadDiagramShape selectedItem)
23.
{
24.
selectedItem.Background = ColorHelper.IMBALLO_SELEZIONATO;
25.
selectedItem.Foreground = ColorHelper.IMBALLO_TITLE_SELEZIONATO;
26.
27.
//Aggiorna il 3D
28.
var macchina = (ModelloCommerciale)selectedItem.Tag;
29.
var macchina3D = macchina.Oggetto3D;
30.
macchina3D.Material =
new
DiffuseMaterial(ColorHelper.IMBALLO_SELEZIONATO);
31.
macchina3D.BackMaterial =
new
DiffuseMaterial(ColorHelper.IMBALLO_SELEZIONATO);
32.
33.
//Gesione trasparenza, รจ necessario per poter vedere trasparenti gli altri oggetti 3D
34.
//bisogna portare da index = 0 gli oggetti selezionati
35.
36.
//Rimuovo l'oggetto 3D attuale
37.
this
.oggettiModel3DGroup.Children.Remove(macchina3D);
38.
//Reinserisco l'oggetto 3D con index = 0
39.
this
.oggettiModel3DGroup.Children.Insert(0, macchina3D);
40.
}
41.
}
Hi,
I'm working with a RadTreeview binded to an ObservableCollection.
All is fine, until I add a new item in my collection, a new row is created, but the left arrow (to expand) doesn't appear.
I have to expand with a double click to let it appear. After that all is fine.
Can someone help me ?
Thanks,
Benoit.
01.
<
telerik:RadTreeView
ItemsSource
=
"{Binding Directories}"
SelectedItem
=
"{Binding SelectedItem, Mode=TwoWay}"
Grid.Row
=
"1"
Background
=
"White"
>
02.
<
telerik:RadTreeView.ItemContainerStyle
>
03.
<
Style
TargetType
=
"telerik:RadTreeViewItem"
>
04.
<
Setter
Property
=
"HorizontalContentAlignment"
Value
=
"Stretch"
/>
05.
</
Style
>
06.
</
telerik:RadTreeView.ItemContainerStyle
>
07.
<
telerik:RadTreeView.ItemTemplate
>
08.
<
HierarchicalDataTemplate
ItemsSource
=
"{Binding FilesList}"
>
09.
<
Grid
HorizontalAlignment
=
"Stretch"
>
10.
<
Grid.ColumnDefinitions
>
11.
<
ColumnDefinition
Width
=
"*"
></
ColumnDefinition
>
12.
<
ColumnDefinition
Width
=
"Auto"
></
ColumnDefinition
>
13.
</
Grid.ColumnDefinitions
>
14.
<
TextBlock
Grid.Column
=
"0"
Text
=
"{Binding Name}"
VerticalAlignment
=
"Center"
/>
15.
<
Button
Grid.Column
=
"1"
HorizontalAlignment
=
"Right"
VerticalAlignment
=
"Center"
Content
=
"Export"
>
16.
</
Grid
>
17.
</
HierarchicalDataTemplate
>
18.
</
telerik:RadTreeView.ItemTemplate
>
19.
</
telerik:RadTreeView
>
I am allowing the user to pan & zoom on the graph, for example through the following:
ChartArea.ZoomScrollSettingsX.ScrollMode = ScrollMode.ScrollAndZoom;
At some point, I set the ScrollMode back to ScrollMode.None and want to reset the ranges of the X & Y axes. I want the ranges to be calculated in the fashion they were when the data were originally drawn.
How can I get the ChartView to recalculate the axis ranges?
Please note that I may add data to the chart before triggering the recalc so just remembering range values before pan/zoom and setting them afterwards won't be sufficient.
I would like to be able to modify the list of operators in my field filter. I know I can do it in the way shown here:
http://docs.telerik.com/devtools/wpf/controls/radgridview/filtering/how-to/howto-change-the-default-selected-filter-operator
But if I am creating my own custom GridViewDataColumn or FilterDescriptor class, is it possible to do it from inside one of those two classes, so I don't have to repeat the same event handlers for every RadGridView that I'm using them in?
Hello Telerik Team,
I have one problem in my WPF project. I was getting issues when we select more than 6000 documents from radgridview after select these documents i was selecting 1 documents . so it was taking near about 45 seconds time to select the single document. so from telerik team someone suggested to update the telerik versions with the newer one. after upgradation all the radmenuitems were not working and some UI things also not working,i have attached the snapshots of the radmenuitems. what i have to do for it to fix these issues.
Regards
Raju Tiwari
Hi all,
I have a RadPieChart with some values, I have a legend with the name of this values and I need set a tooltip to each slide with the names i have in this legend, but i nee do it programatically in C#.
I tried do it with the nameof List<string> that i have to set the legends, but i have no success.
RadChart.Series[0].LabelDefinitions.Add(new ChartSeriesLabelDefinition()
{
Margin = new Thickness(-5, 0, 0, 0),
Binding = new PropertyNameDataPointBinding(SeriesName[0])
});
RadChart.Series[0].LegendSettings = new DataPointLegendSettings();
RadChart.Series[0].LegendSettings.TitleBinding = new PropertyNameDataPointBinding(CategoryName);
RadChart.Series[0].ToolTip = new PropertyNameDataPointBinding(CategoryName);
Hi,
I am using RichTextBox in GridView which is read-only so I want to change cursor style to Arrow. I tried to add Cursor="Arrow" but without success.
The customer has requested the ability to highlight particular cells in a row to copy paste--is this possible?
Secondly, they would also like to do this when selecting multiple rows. To me, this interaction doesn't seem possible, but is it?