This is a migrated thread and some comments may be shown as answers.

TimeBar: Drag&Drop appointmentItem in RadScheduleView - disable date(hh:mm) in left top and bottom right corner

2 Answers 112 Views
TimeBar
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Andrei
Top achievements
Rank 1
Andrei asked on 15 Mar 2012, 01:42 PM

Hello,

     I'm a very novice user of Telerik TimeBar control. For begining I would like to hide the start and end times (hours&minutes) in the appointmentItem while drag&drop(please see attached image).
     Any help/suggestion are welcomed.  
  
   Thanks in adance!

Andrei

2 Answers, 1 is accepted

Sort by
0
Andrei
Top achievements
Rank 1
answered on 15 Mar 2012, 04:09 PM
Hello,

     Meanwhile I had search and found out how it can be done (please see code below). I did not remove the text boxes since I plan to add another information there.
     But still I have one question: Isn't there any other way to only set Text="" for start and end textBox instead creating again the entire style?

Regards,
Andrei
<telerik:RadScheduleView.DragDropHighlightStyle>
     <Style TargetType="telerik:HighlightItem">
         <Setter Property="BorderBrush" Value="{StaticResource DecorationRectangleOuterBorder_DragOver_custom}" />
         <Setter Property="Background" Value="{StaticResource DecorationRectangleBackground_DragOver_custom}" />
         <Setter Property="BorderThickness" Value="1" />
         <Setter Property="Template">
             <Setter.Value>
                 <ControlTemplate>
                     <Border BorderBrush="Black">
                         <Grid>
                             <Border BorderBrush="{StaticResource DecorationRectangleInnerBorder_DragOver_custom}" BorderThickness="1" />
                             <Path Width="8" Height="8" Margin="-2" HorizontalAlignment="Left" VerticalAlignment="Top">
                                 <Path.Data>
                                     <GeometryGroup>
                                         <EllipseGeometry RadiusX="2" RadiusY="2" Center="2 2" />
                                         <LineGeometry StartPoint="3 3" EndPoint="8 8" />
                                     </GeometryGroup>
                                 </Path.Data>
                             </Path>
 
                             <TextBlock x:Name="StartTextBox" Margin="4 2" Foreground="Black" HorizontalAlignment="Left" VerticalAlignment="Top" Text=""/>
                             <Path Width="8" Height="8" Margin="-2" HorizontalAlignment="Right" VerticalAlignment="Bottom">
                                 <Path.Data>
                                     <GeometryGroup>
                                         <EllipseGeometry RadiusX="2" RadiusY="2" Center="6 6" />
                                         <LineGeometry StartPoint="0 0" EndPoint="5 5" />
                                     </GeometryGroup>
                                 </Path.Data>
                             </Path>
                             <TextBlock x:Name="EndTextBox" Margin="4 2" Foreground="Black" HorizontalAlignment="Right" VerticalAlignment="Bottom" Text=""/>
                         </Grid>
                     </Border>
                 </ControlTemplate>
             </Setter.Value>
         </Setter>
     </Style>
 </telerik:RadScheduleView.DragDropHighlightStyle>
0
Yana
Telerik team
answered on 20 Mar 2012, 11:40 AM
Hi Andrei,

I am glad that you've found the solution by yourself.  I am afraid that setting the DragDropHighlightStyle is the only way to customize the required text.

Kind regards,
Yana
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
Tags
TimeBar
Asked by
Andrei
Top achievements
Rank 1
Answers by
Andrei
Top achievements
Rank 1
Yana
Telerik team
Share this question
or