NSArray *imageArr = @[@[@"查看地图",@"map_hy.png"],
@[@"联系号码",@"phone_hy.png"],
@[@"我要咨询",@"zixun_hy.png"],
@[@"预约报名",@"baoming_hy.png"],
]; UIImageView *image = [[UIImageView alloc]initWithFrame:CGRectMake(15, 10, 18, 18)];
image.image = [UIImage imageNamed:imageArr[row][1]];
UILabel *label = [[UILabel alloc]initWithFrame:CGRectMake(38, 10, 100, 18)];
label.font = [UIFont systemFontOfSize:14];
label.text = imageArr[row][0];
[cell.contentView addSubview:image];
[cell.contentView addSubview:label];

  

二维数组在text,image的应用的更多相关文章

  1. jquery解析php通过ajax传过来的json二维数组对象

    ajax获得php传过来的json二维数组对象,jquery解析 php代码: <?php $news = array( '武汉'=>array(1,2,3), '广州'=>arra ...

  2. C#/JS 获取二维数组组合

    C#获取二维数组组合 using System; using System.Collections.Generic; using System.Linq; using System.Text; usi ...

  3. C#读txt文件并写入二维数组中(txt数据行,列未知)

    using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.I ...

  4. perl 二维数组

    perl没有真正的二维数组,所谓的二维数组其实是把一维数组以引用的方式放到另外一个一维数组. 二维数组定义 : my @array1=([1,2],[3,4],[45,9],[66,-5]);     ...

  5. js 如何生成二维数组

    想了几种方法都不能很好的,用js定义二维数组.这种定义,指的是:定义按需确认数组大小. 网上看了下,都是用for循环创建,大小必须提前设定.不是我想要的.(感觉不能和php一样,真是麻烦!) 先贴出代 ...

  6. javascript二维数组

    var a= new Array(new Array(1,2),new Array('b','c')); document.write(a[1][1]); 说白了,就是利用for循环定义二维数组! & ...

  7. php 二维数组传递给 js 问题解决记录

    需求: php从数据库中读取到二维数组.传递到js中 实现步骤: php:json_encode  →   json  →  js:eval 即在php中使用json_encode()将php的二维数 ...

  8. JS table内容转成二维数组,支持colspan和rowspan

    思路:1.先初始化colspan的数据到数组2.根据rowspan和colspan计算th和td的矩阵二次填充数组 说明:需要引用到第三方库jQuery,table中的th和td行和列跨度必须正确 & ...

  9. 二维数组 \n是换行 三目运算符 if语句示例

    今天学习了二维数组 // 1.定义数组array并赋值 // var arr1=[1,2,3,4,5,]; // alert(arr1[2]); 数组的长度就是值的多少 获取数值的长高度=最大下标+1 ...

随机推荐

  1. Javascript页面跳转与浏览器兼容

    用<meta>标签实现的定时跳转: <meta http-equiv="refresh" content="5 url=http://www.baidu ...

  2. Byte、KB、MB、GB、TB、PB、EB是啥以及它们之间的进率

    它们是存储单位 因为计算机存储单位一般用B,KB.MB.GB.TB.PB.EB.ZB.YB.BB来表示,它们之间的关系是: 位 bit (比特)(Binary Digits):存放一位二进制数,即 0 ...

  3. iOS 开发者证书总结

    iOS 证书分两种类型. 第一种为$99美元的,这种账号有个人和公司的区别,公司账号能创建多个子账号,但个人的不能.这种账号可以用来上传app store 第二种为¥299美元的,这种账号只能用于企业 ...

  4. 数据存储: sqlite,coredata plist 归档

    sql 语句  结构化查询语言 通用数据库操作语言1.创建数据库create database 1407EDB2.删除数据库drop database 1407EDB3.备份use master ex ...

  5. (转)Should I use char** argv or char* argv[]

      As you are just learning C, i recommend you to really try to understand the differences between ar ...

  6. jquery file upload 后台收到的文件名中文乱码, filename中文乱码

    在jQuery File Upload.js文件里,在以下这个js中有个成员叫做 _initXHRData, 是一个function, 在这个function的最后部分有一个if-else分支,如下:

  7. self parent $this关键字分析--PHP

    self :    调用本类的静态方法和属性,常量 parent :调用父类的静态方法.属性.普通方法.构造函数,不能调用父类的普通属性 $this :    调用本类的普通方法和属性,如果本类没有就 ...

  8. oracle中anyData数据类型的使用实例

    ---创建waterfallcreate or replace type waterfall is object(name varchar2(30),height number); --创建river ...

  9. 写入和读取LOB类型的对象

    ====写入数据============ create or replace procedure addWaterFallis directions clob; amount binary_integ ...

  10. C++----练习--string 从文件中一个一个单词的读直到文件尾

    从文件中读取单词.并每行显示一个: 1. #include<iostream> #include<string> #include<vector> int main ...