开发者

ListView Headers Don't Show Up

开发者 https://www.devze.com 2022-12-14 07:19 出处:网络
I am doing a windows mobile applicati开发者_JAVA百科on 6.1. I dragged in a listview and went to columns and added columns to my list view. When I run the listview they do not show up.

I am doing a windows mobile applicati开发者_JAVA百科on 6.1.

I dragged in a listview and went to columns and added columns to my list view. When I run the listview they do not show up.

I then tried to add them through C# code on page load with the follow code.

ColumnHeader header = new ColumnHeader();
            header.Text = "gkgag";
            header.Width = 100;
            header.TextAlign = HorizontalAlignment.Center;
            listView1.Columns.Add(header);

this does not work either. Why don't they show up?


You must use detailed view for column headers to be visible.


listView1.View = View.Details;

If that´s not the problem, column headers might be hidden behind windows systembar.

0

精彩评论

暂无评论...
验证码 换一张
取 消