RichTextBox for WinRT
Copying, Cutting, and Pasting Text

The C1RichTextBox control fully supports the clipboard for both plain and rich text through the keyboard (CTRL+C, CTRL+V, CTRL+X) and UI commands for touch displays. Implement cut/copy/paste commands within your AppBar or any other way imaginable. Use the ClipboardMode property to indicate if you want to copy, cut, or paste plain text or rich text.

You can see the code within button_Click events:

The code above allows you to quickly and easily implement copy/cut/paste commands.

C#
Copy Code
private void btnCopy_Click(object sender, Windows.UI.Xaml.RoutedEventArgs e)
         {
             rtb.ClipboardCopy();
         }
private void btnCut_Click(object sender, Windows.UI.Xaml.RoutedEventArgs e)
         {          
                 rtb.ClipboardCopy();          
         }
private void btnPaste_Click(object sender, Windows.UI.Xaml.RoutedEventArgs e)
         {     
                rtb.ClipboardPaste();
             }
         }

 

 


Copyright (c) GrapeCity, inc. All rights reserved.

Product Support Forum  |  Documentation Feedback