Make a listbox in the pages xaml
<ListBox Margin="0,0,0,0" Height="550" Foreground="White" Name="lbSearchList">
<ListBox.ItemTemplate>
<DataTemplate>
<Border BorderThickness="2" Margin="10,0,10,10" Width="460" BorderBrush="#FF404040">
<TextBlock FontSize="22" Foreground="Black" TextTrimming="WordEllipsis" Text="{Binding ClientName}"/>
</Border>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
Make a Client Class Like this
public class Client
{
public string ClientName{get;set;}
}
now in the code of the page where listbox resides
make a Global variable
List<Client> listClient=new List<Client>();
and in the page constructor
listClient.Add(new Client {ClientName="A"});
listClient.Add(new Client {ClientName="B"});
listClient.Add(new Client {ClientName="C"});
lbSearchList.ItemsSource = listClient;
I hope it works