Telerik Forums
UI for WPF Forum
1 answer
140 views

Hello,

I'm working on a project where I use the RadScheduler with the Timeline View. 
I've already added the Appointments and the Resources, but it displays only the Appointments.

The whole thing is going to be a "holiday" planer. So on the left side there are all the employees and on the right side their holidays in the calendar.

Basically there is only one ResourceType, "employee". For the ResourceName i simply use their employee number.

I have the Problem that I see the Appointments in the View, but I don't see the Resources.

On the Debug-Screenshot you can see that there is a Resource with the right Name and Type in each Appointment, so I guess the method works, but I can't see it in the view.

(I really do miss a very simple example Tutorial on the topic of assigning Resources to Appointments)

What am I doing wrong?

Thank you for your help.

Best regards

Dilyan Traykov
Telerik team
 answered on 23 Dec 2022
0 answers
111 views

If I use directly the control Telerik GridViewDataColumn, define the column grid like a Date (DataType="{x:Type sys:DateTime}"), when I click on the filed visualize correctly the Calendar.

But if I use the custom control from GridViewDataColumn when I do click appare this error:

System.InvalidCastException: Impossibile eseguire il cast di oggetti di tipo 'Telerik.Windows.Controls.RadDatePicker' sul tipo 'System.Windows.Controls.TextBox'.

Can you help me to resolve the problem?
Thank You.

Debora
Top achievements
Rank 1
 asked on 23 Dec 2022
0 answers
161 views
When Program start, RadComboBox is Collapsed. 'cbType' RadComboBox item select, not visible. Why RadComboBox not visible?
<Control.Template>
	<ControlTemplate TargetType="{x:Type Mods_UiMod_FrameControls:UiFrameContent}">
		<StackPanel x:Name="Part_MainStack" DataContext="{Binding}">
			<telerik:RadComboBox Grid.Row="3"
								 Grid.Column="1"
								 Height="20"
								 Margin="5 0 5 0"
								 DisplayMemberPath="CODE_NAME"
								 FontSize="11"
								 ItemsSource="{Binding Source=
								 {x:Static Public_Code:CommonCodes.FormTypes}}"
								 SelectedIndex="{Binding SelectedIndexForm,
								 UpdateSourceTrigger=PropertyChanged}"
								 SelectedValuePath="CODE_ID"
								 SelectionBoxTemplate="{StaticResource CodeCBTemplate}"  
								 x:Name="cbType"/>
			<Label Grid.Row="4"
				   Grid.Column="0"
				   Content="Create Month"
				   FontSize="11"
				   Foreground="White" Name="lbCreateMonth">
				   <Label.Style>
					   <Style TargetType="Label">
						   <Setter Property="Visibility" Value="Collapsed"/>
						   <Style.Triggers>
								<DataTrigger Binding="{Binding ElementName=cbType, Path=SelectedIndex}" Value="0">
									<Setter Property="Visibility" Value="Visible"/>
								</DataTrigger>
						   </Style.Triggers>
					   </Style>
				   </Label.Style>
			</Label>
			<telerik:RadComboBox Grid.Row="4"
								 Grid.Column="1"
								 Height="20"
								 Margin="5 0 5 0"
								 DisplayMemberPath="CODE_NAME"
								 FontSize="11"
								 ItemsSource="{Binding Source={x:Static Public_Code:CommonCodes.TimeMonthCodes}}"
								 SelectedIndex="{Binding SelectedIndexCreateMonth,
														 UpdateSourceTrigger=PropertyChanged}"
								 SelectedValuePath="CODE_ID"
								 SelectionBoxTemplate="{StaticResource CodeCBTemplate}" Name="cbCreateMonth">
				<telerik:RadComboBox.Style>
					<Style TargetType="{x:Type telerik:RadComboBox}">
						<Setter Property="Visibility" Value="Collapsed"/>
						<Style.Triggers>
							<DataTrigger Binding="{Binding ElementName=cbType, Path=SelectedIndex}" Value="0">
								<Setter Property="Visibility" Value="Visible"/>
							</DataTrigger>
						</Style.Triggers>
					</Style>
				</telerik:RadComboBox.Style>
			</telerik:RadComboBox>
		<StackPanel x:Name="Part_MainStack" DataContext="{Binding}">
	</ControlTemplate>
</Control.Template>

Jae Myoung
Top achievements
Rank 1
 updated question on 22 Dec 2022
0 answers
127 views

How to compare two MapPinPoint

MapPinPoint mapPinPoint1 = new MapPinPoint();
MapPinPoint mapPinPoint2 = new MapPinPoint();

How can you check if they are equal?

Ohad
Top achievements
Rank 3
Bronze
Iron
Iron
 asked on 22 Dec 2022
1 answer
175 views

Hi,

I am using a TreeListView to display financial data (element with costs per month) with sub-totals as the parent rows. The data structure is thus homogenous and a good fit for the TreeListView.  The binding and data work perfectly, but now I would like to refine the styling to show a greater contrast between parent and child (e.g. make sub-total rows bold). Is there an simple way to do this?

Renier Pretorius
Top achievements
Rank 2
Iron
Iron
Iron
 answered on 21 Dec 2022
1 answer
182 views

Hello,

I'm trying to set up a RadGridView to display a RadEntityFrameworkCoreDataSource source using code-behind (currently a requirement) and cannot get the grid to populate with any data. I can access the data by using LINQ just fine, and can populate the grid using a ToList() version of that data, but I believe that it's just a copy of the data, and cannot be modified and saved to the original context.

Here's an example of what I'm trying to do:

var options = new DbContextOptionsBuilder<Test_Context>();
options.UseSqlServer(ConnectionString);
using var testContext= new Test_Context(options.Options);

RadEntityFrameworkCoreDataSource source = new()
{
    Name = "coreDataSource",
    DbContext = testContext,
    QueryName = "TblCustomer"
};

// This doesn't populate the grid
rgvCustomers.ItemsSource = source.DataView;
                
// This populates the grid
var customerList = textContext.TblCustomer.Where(customer => customer.Id != -1).ToList();
rgvCustomers.ItemsSource = customerList ;

How do I get the RadEntityFrameworkCoreDataSource to query the data so that it can populate the grid?

Also, how would I go about only querying the customers with an Id != -1 using said Data Source? Is that as simple as setting the filters, then querying?

I'm new to this, so apologies if I've missed a simple step.

Dilyan Traykov
Telerik team
 answered on 20 Dec 2022
1 answer
220 views

   <telerik:RadAutoCompleteBox TextSearchMode="Contains" SelectedItem="{Binding Entity, Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" DisplayMemberPath="Name" HorizontalAlignment="Stretch" SelectionMode="Single"  Margin="125,100,0,10" VerticalAlignment="Top" Width="Auto" Grid.Column="0" Name="customerACB" SearchTextChanged="customerACB_SearchTextChanged" AutoCompleteMode="Suggest" >
                                        <telerik:RadAutoCompleteBox.DropDownItemTemplate>
                                            <DataTemplate>
                                                <StackPanel Orientation="Horizontal">
                                                    <Label Content="{Binding Code}" Width="70"  />
                                                    <Label Content="{Binding Name}" Width="310" />
                                                </StackPanel>
                                            </DataTemplate>
                                        </telerik:RadAutoCompleteBox.DropDownItemTemplate>
                                    </telerik:RadAutoCompleteBox>

 


Currently, i am able to search using "Name". If I change displaymemberpath to code it will show the result if the search string match with "code"
I need to search using both values "Name" and "code".

Martin Ivanov
Telerik team
 answered on 16 Dec 2022
3 answers
802 views

Hi - 

I have a RadGridView that populates dynamically based on columns present in an Excel spread-sheet. I'm able to create the columns but not having luck getting the ToolTip to display. 

Thanks in advance - Jon

Here is my code snippet: 

               foreach (DataColumn column in dt.Columns)
                {
                    Telerik.Windows.Controls.GridViewDataColumn gridviewDataColumn = new Telerik.Windows.Controls.GridViewDataColumn
                    {
                        Header = column.ColumnName,
                        Name = column.ColumnName,
                        DataMemberBinding = new System.Windows.Data.Binding(column.ColumnName),
                        // Tooltip = ??? 
                    };

                    dtg_PreviewMapGrid.Columns.Add(gridviewDataColumn);
                }
                dtg_PreviewMapGrid.ItemsSource = dt;

 

Antti
Top achievements
Rank 1
Iron
 updated answer on 15 Dec 2022
0 answers
128 views
Hi,

I am looking for a component to print a Year Calendar with selected days marked.

Just printing, no dialogboxes etc.

Is there a component and an example how to do this?

Kind regards,
André
André
Top achievements
Rank 1
 asked on 14 Dec 2022
1 answer
126 views
Hi, 
Using Telerik.UI.for.Wpf.NetCore.Xaml  (2022.3.912).
I'm getting an error for the taskboard the first time it loads
Both 'ContentTemplate' and 'ContentTemplateSelector' are set;  'ContentTemplateSelector' will be ignored. RadTaskBoardItem:'RadTaskBoardItem' (Name='')
this error as many as the Item task that appears.

Then when I exit and return to the taskboar page, another error appears:
Cannot find source: RelativeSource FindAncestor, AncestorType='Telerik.Windows.Controls.RadTaskBoard', AncestorLevel='1'

        <telerik:RadTaskBoard x:Name="RadTaskBoard01"  Grid.Row="3" 
                              ItemsSource="{Binding TaskboardCollView}" 
                              GroupMemberPath="State"
                              Background="{StaticResource StripeColor}" 
                              AutoGenerateColumns="False">
            <telerik:RadTaskBoard.DragDropBehavior>
                <localservice:CustomTaskBoardDragDropBehavior/>
            </telerik:RadTaskBoard.DragDropBehavior>
            <telerik:RadTaskBoard.Columns>
                <telerik:TaskBoardColumn GroupName="NEW" Header="Red"  />
                <telerik:TaskBoardColumn GroupName="INPROGRESS" Header="Yellow" />
                <telerik:TaskBoardColumn GroupName="REVIEWED" Header="Gray" />
                <telerik:TaskBoardColumn GroupName="DONE" Header="ForestGreen" />
            </telerik:RadTaskBoard.Columns>
            <telerik:RadTaskBoard.ColumnHeaderTemplate >
                <DataTemplate>
                    <Grid>
                        <Grid.ColumnDefinitions >
                            <ColumnDefinition/>
                            <ColumnDefinition/>
                            <ColumnDefinition/>
                        </Grid.ColumnDefinitions>
                        <Border  Width="17" Grid.Column="0" Background ="{Binding Header}"  BorderThickness="1" BorderBrush="Black" CornerRadius="10" ></Border>
                        <TextBlock Grid.Column="1" Text="{Binding GroupName}"  HorizontalAlignment="Left"  />
                        <TextBlock Grid.Column="2" Margin="10 ,0 ,10, 0" Text="{Binding Items.Count}" HorizontalAlignment="Right" />
                    </Grid>
                </DataTemplate>
            </telerik:RadTaskBoard.ColumnHeaderTemplate>
            <telerik:RadTaskBoard.ItemTemplate>
                <DataTemplate>
                    <Grid >
                        <Grid.ColumnDefinitions >
                            <ColumnDefinition Width="5"/>
                            <ColumnDefinition/>
                        </Grid.ColumnDefinitions>
                        <Grid.RowDefinitions >
                            <RowDefinition/>
                            <RowDefinition Height="25"/>
                        </Grid.RowDefinitions>
                        <Grid Grid.Row="0" Grid.RowSpan="2" Grid.Column ="0" 
                              Background="{Binding CategoryName, Converter={StaticResource CategoryToColour}}">
                        </Grid>
                        <StackPanel  Grid.Row="0"  Grid.Column ="1" >
                            <TextBlock Text="{Binding Parenttitle}"  Margin="15,0,5,0"   Foreground="{StaticResource StripeColor}"  FontSize="16" TextWrapping="Wrap"  />
                            <StackPanel Visibility="{Binding Isparent, Converter={StaticResource BoolToVisible}}">
                                <TextBlock Text="Have Sub Task"
                                           HorizontalAlignment="Right"
                                           Margin="0,0,5,0"
                                           Foreground="Red"
                                           FontWeight="Bold"
                                           FontStyle ="Italic" 
                                           FontSize="12" />
                            </StackPanel>
                            <StackPanel Visibility="{Binding Title, Converter={StaticResource EmptyToVisible }}">
                                <TextBlock Text="{Binding Title}"
                                           Margin="15,0,5,0"
                                           Foreground="Brown"
                                           TextWrapping="WrapWithOverflow"
                                           FontSize="14" />
                            </StackPanel>
                            <TextBlock Text="{Binding Description}"
                                       Margin="15,0,5,0"
                                       TextWrapping="Wrap"
                                       FontSize="14" />
                        </StackPanel>

                        <TextBlock Text="{Binding Assignee}"  Grid.Row="1"   Grid.Column ="1" Margin="15,0,15,0" Foreground="ForestGreen"      
                                   FontSize="16" FontStyle="Italic"  HorizontalAlignment="Right" VerticalAlignment="Bottom" />
                    </Grid>
                </DataTemplate>
            </telerik:RadTaskBoard.ItemTemplate>
        </telerik:RadTaskBoard>

Stenly
Telerik team
 answered on 13 Dec 2022
Narrow your results
Selected tags
Tags
GridView
General Discussions
Chart
RichTextBox
Docking
ScheduleView
ChartView
TreeView
Diagram
Map
ComboBox
TreeListView
Window
RibbonView and RibbonWindow
PropertyGrid
DragAndDrop
TabControl
TileView
Carousel
DataForm
PDFViewer
MaskedInput (Numeric, DateTime, Text, Currency)
AutoCompleteBox
DatePicker
Buttons
ListBox
GanttView
PivotGrid
Spreadsheet
Gauges
NumericUpDown
PanelBar
DateTimePicker
DataFilter
Menu
ContextMenu
TimeLine
Calendar
Installer and Visual Studio Extensions
ImageEditor
BusyIndicator
Expander
Slider
TileList
PersistenceFramework
DataPager
Styling
TimeBar
OutlookBar
TransitionControl
FileDialogs
Book
ToolBar
ColorPicker
TimePicker
MultiColumnComboBox
SyntaxEditor
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
WatermarkTextBox
DesktopAlert
BarCode
SpellChecker
DataServiceDataSource
EntityFrameworkDataSource
RadialMenu
ChartView3D
Data Virtualization
BreadCrumb
ProgressBar
Sparkline
LayoutControl
TabbedWindow
ToolTip
CloudUpload
ColorEditor
TreeMap and PivotMap
EntityFrameworkCoreDataSource (.Net Core)
HeatMap
Chat (Conversational UI)
VirtualizingWrapPanel
Calculator
NotifyIcon
TaskBoard
TimeSpanPicker
BulletGraph
Licensing
WebCam
CardView
DataBar
FilePathPicker
PasswordBox
Rating
SplashScreen
Accessibility
Callout
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?