Jqgrid添加对话框如何更改字段的宽度和高度?

时间:2014-01-28 09:47:08

标签: asp.net jqgrid jqgrid-asp.net

我正在使用jqgrid asp.net组件。如何在添加和编辑对话框中更改字段宽度和高度(文本框或组合)?

谢谢

1 个答案:

答案 0 :(得分:0)

在最后我发现它

1您需要指定edittype属性

2之后指定editfiled属性标记

用于文字区域

 <trirand:JQGridColumn DataField="Remarks" HeaderText="Remarks" Editable="true" EditType="TextArea">
                        <Formatter>
                            <trirand:CustomFormatter FormatFunction="formatRating" UnFormatFunction="unformatRating" />
                        </Formatter>
                        <EditFieldAttributes>
                            <trirand:JQGridEditFieldAttribute Name="cols" Value="80" />
                            <trirand:JQGridEditFieldAttribute Name="rows" Value="6" />
                        </EditFieldAttributes>
                    </trirand:JQGridColumn>
  

用于文本框

<trirand:JQGridColumn DataField="Design" HeaderText="Design" Editable="true" EditDialogFieldSuffix=" (MAX - 10)">
                        <Formatter>
                            <trirand:CustomFormatter FormatFunction="formatRating" UnFormatFunction="unformatRating" />
                        </Formatter>
                        <EditFieldAttributes>
                            <trirand:JQGridEditFieldAttribute Name="size" Value="2" />
                        </EditFieldAttributes>
                    </trirand:JQGridColumn>

enter image description here