Skip to main content Skip to footer

What's New: C1Popup for Windows Phone

New in 2012 v2, the C1Popup control is an advanced version of the primitive Popup class with added features such as animation and back button support. Popups are convenient because they eliminate the need of having to create a separate page to display or gather additional information from the user. C1Popup behaves like a separate page because users can instinctively escape the popup by pressing the hard back button. Using C1Popup is very simple. You can declare the popup in XAML on your page like this:


<c1:C1Popup x:Name="c1Popup1">  
    <!--Content here-->  
</c1:C1Popup>  

Or you can create one at run-time with any UserControl as its content like this:


C1Popup popup = new C1Popup();  
MyUserControl control = new MyUserControl();  
popup.Content = control;  
// open popup  
popup.IsOpen = true;  

To open and close C1Popup programmatically you set the IsOpen property. When the control opens it sets focus to itself, so the virtual keyboard (SIP) will close automatically. C1Popup is a very useful control for nearly any kind of Silverlight app on the Phone.

RichTextBox Formatting Sample

We used C1Popup to complete the formatting demo for C1RichTextBox. Just like the format button in Microsoft Word for Windows Phone, we used C1Popup to display many format features supported in C1RichTextBox.

This sample also shows a popup for inserting/editing a hyperlink, as well as undo functionality (not using any popup).

ComponentOne Product Manager Greg Lutz

Greg Lutz

comments powered by Disqus