progressring controls
The previous section explains how the ProgressBar control is used, and both the progressring control and the ProgressBar control are used to display the progress information of the application's current task, except that the Progressring control displays progress information in a style that is not sure of the progress loop.
In a XAML file, the use of the Progressring control is as follows:
<progressring .../>
progressring Control has an important property A IsActive that indicates whether an indeterminate progress ring is displayed. If the property value is true, the indeterminate progress loop is displayed. If the property value is false, the indeterminate progress ring is hidden.
The following is an example of how the Progressring control is used .
Create a new Windows store blank application project and name Progressringdemo to add the following code to the grid element of the MainPage.xaml file.
<textblock horizontalalignment= "Center" fontsize= "margin=" 505,109,644,0 "text= " Indeterminate Progress Ring style "textwrapping=" Wrap "verticalalignment=" Top "height=" "width=" 217 "/> "
<progressring horizontalalignment= "left" isactive= "True" margin= "535,168,0,0" verticalalignment= "Top" Height= " "Width=" 144 "/>
In the preceding code, a TextBlock text block and a progressring control are added, TextBlock text blocks are used to display the "Indeterminate Progress Loop Style" text message, the IsActive property value of the Progressring control is set to True, The indeterminate progress loop is displayed.
Run the program and you can see that the indeterminate progress ring is spinning, as shown in effect 4-25.
Figure 4-25 Indeterminate Progress ring style
Win10 series: C # App Control Basics