WPF fills mockup data in ListView

Source: Internet
Author: User
Tags header xmlns

Using blend to do visual design, often encounter problems that don't know how to go to ListView for vacation data. This provides a method. For your reference. If there is a simpler way, I hope you will not hesitate to enlighten us.

The code is as follows:

<window
Xmlns= "Http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x= "Http://schemas.microsoft.com/winfx/2006/xaml"
Xmlns:s= "Clr-namespace:system;assembly=mscorlib"
X:class= "Listviewdata.mainwindow"
X:name= "Window"
title= "Demo window"
Width= "height=" >
<grid x:name= "LayoutRoot" >
<ListView>
<ListView.View>
<GridView>
<gridviewcolumn header= "Value"
Displaymemberbinding= "{Binding.}" />
<gridviewcolumn header= "Length"
displaymemberbinding= "{Binding Length}"/>
</GridView>
</ListView.View>
<ListView.Items>
<s:String>a</s:String>
<s:String>bb</s:String>
</ListView.Items>
</ListView>
</Grid>
</Window>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.