如何在sharepoint webpart中显示多行文本框的字段?
当我点击webpart上的“修改共享webpart”时,我希望文本字段给我一个多行框
感谢
答案 0 :(得分:5)
像
这样的东西var textBox = new TextBox();
textBox.TextMode = TextBoxMode.MultiLine;
答案 1 :(得分:2)
您还必须将渲染编写为对您所处的模式敏感:
if( (WebPartManager.DisplayMode == WebPartManager.DesignDisplayMode) ||
(WebPartManager.DisplayMode == WebPartManager.EditDisplayMode) ) {
//Show your textbox
} else {
//Render as text
}