In this article you will learn about reversing numbers. A number with the most significant digit becoming the least significat digit and vice versa is called a reversed number. To implement the reverse number logic in a Windows Store app I use a TextBox that accepts the number as input and a Textblock to print the output and a button click for the logic.
Use the following procedure to make the reverse number app.
Step 1
First of all you have to create a new Windows Store Application.
- Open Visual Studio 2012
- "File" -> "New" -> "Project..."
- Choose Template: "Visual C#" -> "Window Store app"
- "Blank App (XAML)", then rename the application

Step 2
Write the following simple XAML code for "Mainpage.Xaml" (that is available in Solution Explorer):
<Page
x:Class="reverse_number_app.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:reverse_number_app"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d">
<Grid Background="Red">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="461*"/>
<ColumnDefinition Width="905*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="97*"/>
<RowDefinition Height="52*"/>
<RowDefinition Height="33*"/>
<RowDefinition Height="43*"/>
<RowDefinition Height="543*"/>
</Grid.RowDefinitions>
<TextBlock Text=" Do you want to Reverse Number" FontSize="20" FontFamily="Arial" FontWeight="ExtraBold" Foreground="White" Grid.Column="1" Grid.Row="1"/>
<TextBlock Text="Enter number" FontSize="20" FontFamily="Arial" FontWeight="ExtraBold" Foreground="White" Grid.Column="0" Grid.Row="2" TextAlignment="Right"></TextBlock>


Comments
Join the conversation! Your thoughts help the community grow.