ExtJs之Ext.each
<!DOCTYPE html>
<html>
<head>
<title>ExtJs</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<link rel="stylesheet" type="text/css" href="ExtJs/packages/ext-theme-crisp/build/resources/ext-theme-crisp-all.css">
<script type="text/javascript" src="ExtJs/ext-all.js"></script>
<script type="text/javascript" src="ExtJs/bootstrap.js"></script>
<script type="text/javascript" src="ExtJs/packages/ext-theme-crisp/build/ext-theme-crisp.js"></script>
<script type="text/javascript">
Ext.onReady(function(){
var panel = new Ext.Panel({
title: 'SAMPLE',
renderTo: 'sub1',
width: '300px',
html: '<div style="height:160px"></div>'
});
var array = [], i;
for(i=0;i<10;i++){
array.push(i);
}
function fn(item, index, allItems){
if(item>5){
return false;
}else{
allItems[index] = item + "_st"
}
}
function fn1(item, index, allItems){
if(index>0)
return false;
Ext.Msg.alert("最后的处理结果",
"<div style='width:160px'>最后的集合为:" + allItems +"</div>");
}
Ext.each(array, fn);
Ext.each(array, fn1);
});
</script>
</head>
<body>
<div id=sub1></div>
</body>
</html>

ExtJs之Ext.each的更多相关文章
- ExtJS学习-----------Ext.Object,ExtJS对javascript中的Object的扩展
关于ExtJS对javascript中的Object的扩展.能够參考其帮助文档,文档下载地址:http://download.csdn.net/detail/z1137730824/7748893 以 ...
- ExtJs之Ext.util.TextMetrics
<!DOCTYPE html> <html> <head> <title>ExtJs</title> <meta http-equiv ...
- ExtJs之Ext.util.TaskRunner
<!DOCTYPE html> <html> <head> <title>ExtJs</title> <meta http-equiv ...
- ExtJs之Ext.util.MixedCollection
<!DOCTYPE html> <html> <head> <title>ExtJs</title> <meta http-equiv ...
- ExtJs之 Ext.JSON
<!DOCTYPE html> <html> <head> <title>ExtJs</title> <meta http-equiv ...
- ExtJs之Ext.util.Format
<!DOCTYPE html> <html> <head> <title>ExtJs</title> <meta http-equiv ...
- ExtJs之Ext.util.ClickRepeater
<!DOCTYPE html> <html> <head> <title>ExtJs</title> <meta http-equiv ...
- ExtJs之Ext.util.CSS
<!DOCTYPE html> <html> <head> <title>ExtJs</title> <meta http-equiv ...
- ExtJs之Ext.core.DomQuery
<!DOCTYPE html> <html> <head> <title>ExtJs</title> <meta http-equiv ...
- ExtJs之Ext.core.DomHelper.append
<!DOCTYPE html> <html> <head> <title>ExtJs</title> <meta http-equiv ...
随机推荐
- hdu 5264 pog loves szh I
题目连接 http://acm.hdu.edu.cn/showproblem.php?pid=5264 pog loves szh I Description Pog has lots of stri ...
- android开发中经常遇到的问题汇总
大家都在为项目开发成功而喜悦,但可不知成功的路上是会经常出错的,下面是我碰到的一些错误集合! [错误信息] [2011-01-19 16:39:10 - ApiDemos] WARNING: Appl ...
- Android Cookie共享到WebView避免再次登录(保持登录状态)
最近在做项目时用到了webview打开指定链接的网页,可已经把webview设置了cookie但始终跳转到登录页面,这明显是cookie没有设置成功导致webview没有将设置好的cookie发送出去 ...
- jquery一个控件绑定多个事件
jQuery("#id").bind("click mouseover",function(){}) // 两个事件中间有空格 $("p" ...
- 教你怎么安装Redis
以下命令以root用户运行:#cd /tmp/#wget http://redis.googlecode.com/files/redis-2.6.11.tar.gz#tar xzf redis-2.6 ...
- Android实现页面跳转、ListView及其事件
Android实现页面跳转.ListView及其事件 开发工具:Andorid Studio 1.3 运行环境:Android 4.4 KitKat 工程内容 进入主页面后,使用ListView实现特 ...
- web 性能忧化(IIS篇)
1. 调整IIS 7应用程序池队列长度 由原来的默认1000改为65535. IIS Manager > ApplicationPools > Advanced Settings 2. ...
- unity 协同
void Update () { if(Input .GetKeyDown (KeyCode .W )) { StartCoroutine ("Test"); } } IEnume ...
- EasyUI 在aspx页面显示高度不正常解决办法
<body class="easyui-layout"> <form id="form1" runat="server"& ...
- Netsharp快速入门(之14) 销售管理(报表A 热销滞销品统计)
作者:秋时 杨昶 转载须说明出处 4.5 销售报表 4.5.1 热销滞销品统计 1.建立部件工作区,主部件选择报表.统计表,辅部件选择查询方案 2.设置报表模版.选择主部件,选择工具-报 ...