[英]Visualization SPmenuField in SPGridView
I have created SPGridView
and added one SPMenuField
as the first column and some BoundFields
. 我创建了SPGridView
并添加了一个SPMenuField
作为第一列以及一些BoundFields
。 Then I added MenuTemplate
to the first column. 然后,我将MenuTemplate
添加到第一列。 But there are rectangles with white color border. 但是也有带有白色边框的矩形。 I want to hide them. 我想把它们藏起来。 How can I do it ? 我该怎么做 ?
Here is the code I use: 这是我使用的代码:
SPMenuField colMenu = new SPMenuField();
colMenu.HeaderText = "Title";
colMenu.TextFields = "Title";
colMenu.MenuTemplateId = "TitleListMenu";
colMenu.NavigateUrlFields = "WebId, ListId, ID";
colMenu.NavigateUrlFormat = "default.aspx?WebID={0}&ListID={1}&ListItemID={2}";
colMenu.TokenNameAndValueFields = "Param1=ID";
colMenu.SortExpression = "Title";
MenuTemplate typeListMenu = new MenuTemplate();
typeListMenu.ID = "TitleListMenu";
// ... //
Controls.Add(typeListMenu);
customGridView.Columns.Add(colMenu);
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.