导航:首页 > 编程语言 > extjs滚动条计算

extjs滚动条计算

发布时间:2023-04-14 05:37:52

① Extjs怎么在panel面板里面设置滚动条

ExtJS API:
autoScroll : Boolean
True表示为在面板body元素上,设置overflow:\\'auto\\'...
True表示为在面板body元素上,设置overflow:\\'auto\\'和出现滚动条false表示为裁剪所专有溢出的属内容(默认为false)。True to use overflow:\\'auto\\' on the panel\\'s body element and show scroll bars automatically when necessary, false to clip any overflowing content (defaults to false).

对panle设置该属性为true

② extjs 中bbar中数据太多,屏幕显示不全需要有在bbar设置滚动条,求大神指导....

换行显示吧,滚动条的即使弄上也不好看,不好操作的,呵呵。

弄成两行,这样干:

自定义一个bbar,例如:

varmybbar=[{
text:'刷新'
},{
text:'新增'
}];

再定一个bbar,分页的工具条bar(普通的bar也行),例如:

varotherbar=newExt.PagingToolbar({
store:store,
pageSize:pageSize,
displayInfo:true,
displayMsg:"当前显示从{0}条到{1}条,共{2}条",
items:[{
text:'修改'
},"-",{
text:'删除'
}]
});

然后在grid中这样:

vargrid=newExt.grid.GridPanel({
......
bbar:mybbar,//第一个bar
listeners:{
render:function(data){
otherbar.render(grid.bbar);//另一个bar
}
}

你试试~~~

③ extjs中grid滚动条怎么加

var userGrid = new Ext.grid.GridPanel({
frame:true,
loadMask:true,
tbar:toolbar,
store:userStore,
stripeRows:true,

viewConfig:{
autoFill:true
//forceFit:true
},
。。。。。。
});

new Ext.Viewport({
layout:'border',
items:[{
contentEl:'toptitle',
bodystyle:'background-color:#BBCCEE;',
region:'north',
height:134
},{
//contentEl:'usergrid-div',
region:'center',
layout: 'fit',
border:true,
items:[userGrid]
}]
});

-------------------------------

var grid = new Ext.grid.GridPanel({
2 autoHeight: true,
3 autoWidth:true,
4 autoScroll: true,
5 title: '<spanstyle=font-weight:bolder;line-height:25px;font-size:18px;><center>“大剂量堵水”措施不同井类型对比表</center></span>',
6 loadMask: true,
7 renderTo: 'grid',
8 store: store,
9 cm: cm,
10 collapsible: true,
11 bbar: new Ext.PagingToolbar({
12 pageSize: 100,
13 store: store,
14 displayInfo: true,
15 displayMsg: '显示第{0}条到第{1}条记录,一共{2}条',
16 emptyMsg: '没有记录'
17 })
18 });
19
20 });
21 </script>
22 </head>
23 <bodystyle=" text-align:center;">
24 <divid="Contain" style="text-align:left;width:1000px;">
25 <divid="grid" style="width:1000px;"></div>
26 </div>
27 </body>

autoHeight: true,autoWidth:true这两个属性是不起作用的。这里要Ext的Grid的滚定条必须显示出来就必须设置固定的Grid宽度(以像素为单位)。

Grid中你加入 width: Ext.get("content").getWidth(), height: Ext.get("content").getHeight()然后再看下你的效果。

如果这个实例你能运行,但是你机器上的代码不能运行,可否提供一个Ext的版本号,以供来测试解决这个问题。

这个问题已经解决了,解决方法是把autoHeight: true, autoWidth:true,改成具体的数值就行了。
Ext的Grid宽高必须是给定的明确数值的。
------------------

var grid = new Ext.grid.GridPanel( {
renderTo : 'Container',
width : gridWidth,
stripeRows : true,
enableHdMenu:false,
autoScroll : true,
autoHeight : true,
columnLines : true,
store : new Ext.data.ArrayStore( {
fields : fields,
data : gridData
}),
columns : columns,
viewConfig : {
forceFit : true
}
});

④ Extjs 如何设置TextArea滚动条 位于底部

把textArea放到一个具有底部滚动条的组件里面就可以了,可以自动的内出现的.


方法容:

if(tab.rendered){
tab.getEl().down('textarea').dom.scrollTop=99999;
}

⑤ 请问extjs 6 grid怎么实现合计,合计行要固定在表格下面,不随纵向滚动条滚,但要随横向滚动

简单给个代码说明一下:
var grid = new Ext.grid.GridPanel({
......(其他属性配置略)
columns: [
{header: '第一列', dataIndex: 'column1'},
{header: '第二列', dataIndex: 'column2'},
{header: '总计', dataIndex: 'column1',renderer : function(value,metadata,reocrd){
//这里面做总计计算
var sum = record.data.column1+reocrd.data.column2;
//或者 var sum = value+reocrd.data.column2;
return sum;
}
},
],
......(其他属性配置略)
});

⑥ extjs怎么加上滚动条,而且要将分页的一栏放在页面的最下面,而不是紧接着数据的最后一条

你用了tbar就没想到bbar?
dockedItems:[{
xtype:'pagingtoolbar',
store:'QueryFindPointStore',
dock:'bottom',
displayInfo:true,
displayMsg:'显示 {0} - {1}条记录,总共 {2}条记录',
emptyMsg:'暂无数据'
}],
换成
bbar:{
xtype:'pagingtoolbar',
store:'QueryFindPointStore',
displayInfo:true,
displayMsg:'显示 {0} - {1}条记录,总共 {2}条记录',
emptyMsg:'暂无数据'
},

⑦ ExtJS 如何实现Grid每列自适应宽度

: function(value, p, r) ,
这样就显示四个星号了,不过最好在服务端就转换了,比较安全。

⑧ Extjs(3.0)中grid的滚动条,两个gridpanel,拉动其中一个gridpanel的滚动条,另外一个滚动条也会跟着联动

Ext渲染到界面上都是解析成html代码的,你用火狐firebug找到页面中存放滚动条的回div,
var obj=Ext.get('div_id');
obj.on('scroll',functionName);//绑定答滚动事件

function functionName(){
//do something

}

⑨ EXTJS的combo组件的下拉选项框的高度和垂直滚动条如何设置

设置combo的一个属性:

maxHeight:100,//下拉列表的最大高度像素值

阅读全文

与extjs滚动条计算相关的资料

热点内容
一组数据2的方差是多少 浏览:535
电脑设置删除显示找不到文件 浏览:454
中国证券app有哪些 浏览:890
天正施工图教程 浏览:428
家庭网络有什么 浏览:126
红米升级系统找不到私密文件 浏览:557
360卫士文件功能描述 浏览:350
魅蓝e2升级yunos 浏览:381
修改ipadID密码 浏览:308
男生去哪里学编程 浏览:772
腻子数据怎么恢复 浏览:699
win10特殊配置文件登录 浏览:55
可视电话电源网站封住了怎么办 浏览:811
如何打印word批注 浏览:152
qq在线表格换成word文件 浏览:138
word文档里找不到文件这栏 浏览:969
如何塑造网站内容公信力 浏览:502
文件传阅系统怎么取消 浏览:392
苹果付费app从哪里扣费 浏览:496
我的咖啡厅快速升级 浏览:559

友情链接