How to use RadConversationView Control without action button?

2 posts, 1 answers
  1. Deepak
    Deepak avatar
    5 posts
    Member since:
    Jul 2012

    Posted 25 Jun 2013 Link to this post

    Hi,
       I would like to implement the RadConverstion Control without an action button so that i can use an application bar button to send the messages.Can anyone help me with this? 

    Thank you.

  2. Answer
    Victor
    Admin
    Victor avatar
    1351 posts

    Posted 27 Jun 2013 Link to this post

    Hi Deepak,

    You can simply set the TextBoxTemplate property to a data template of your choice. The only requirement is that you set the x:Name property of your text box to PART_TextBox. Then in this template, you can set the ActionButtonVisibility of RadTextBox to Collapsed. Here is the default text box template for your convenience:

    <DataTemplate>
        <Grid>
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="*"/>
                <ColumnDefinition Width="3*"/>
            </Grid.ColumnDefinitions>
             
            <primitives:RadPointerContentControl Grid.Column="1"
                                                 TargetPoint="160, 300">
                <primitives:RadPointerContentControl.PointerTemplate>
                    <DataTemplate>
                        <Polygon Width="12"
                                 Height="24"
                                 Points="0,0 12,0 12,12"
                                 StrokeThickness="0"
                                 RenderTransformOrigin="0.5, 0.5"/>
                    </DataTemplate>
                </primitives:RadPointerContentControl.PointerTemplate>
     
                <telerikPrimitives:RadTextBox x:Name="PART_TextBox"
                                              ActionButtonVisibility="Visible">
                    <telerikPrimitives:RadTextBox.ActionButtonStyle>
                        <Style TargetType="telerikTextBox:TextBoxActionButton">
                            <Setter Property="ButtonType"
                                    Value="Custom"/>
                            <Setter Property="RestStateImageSource"
                                    Value="/Telerik.Windows.Controls.Data;component/ConversationView/Images/SendIcon.png"/>
                        </Style>
                    </telerikPrimitives:RadTextBox.ActionButtonStyle>
                </telerikPrimitives:RadTextBox>
            </primitives:RadPointerContentControl>
        </Grid>
    </DataTemplate>

    Regards,
    Victor
    Telerik
    Have a suggestion or face a problem - you can use the Ideas & Feedback portal to submit ideas, feedback and vote for them.
  3. DevCraft banner
Back to Top