开发者

how to convert string to listviewitem?

I try to convert string to ListViewItem:

ListViewItem str = (开发者_C百科ListViewItem)Convert.ChangeType(az, typeof(ListViewItem));

but it doesn't work. What is wrong in this code?


I am not sure I get why you are trying to change the type of a string to ListViewItem. I'm pretty sure that what you actually want to do is create a ListViewItem out of a string using regular construction:

ListViewItem item = new ListViewItem(az);
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜