本帖最后由 zhaoyongakng 于 2012-09-14 13:01:17 编辑

解决方案 »

  1.   

    首先,List<Map<String, Object>> list = new ArrayList<Map<String, Object>>();
    这句是多余的,list已经是成员变量了
     public void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            setContentView(R.layout.main);
            LayoutInflater _LayoutInflater = LayoutInflater.from(this);
            View _View = _LayoutInflater.inflate(R.layout.main, null);
            InitList(_View);
        }
    onCreate方法改为
    public void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            setContentView(R.layout.main);
            InitList();
        }
    把InitList()中ListView _ListView = (ListView) _View.findViewById(R.id.lv_ls_Ent);
    直接改为ListView _ListView = (ListView)findViewById(R.id.lv_ls_Ent);
    这样你就可以进入getview方法了(之前根本都没进入getview方法,当然显示不了数据啊~~)
      

  2.   

    我把
    List<Map<String, Object>> list = new ArrayList<Map<String, Object>>();
    这句话去掉后,程序直接强制退出啊...
    然后我不去掉并且,按你说的改了,还是显示不出来数据啊?
      

  3.   

    LayoutInflater _LayoutInflater = LayoutInflater.from(this);
            View _View = _LayoutInflater.inflate(R.layout.main, null);
    没看懂要这个干啥,直接删掉
      

  4.   

    大致看了下,也没找到错误,不过楼主如果是想重载adapter的话,应该把要显示的图片啊什么的提出来封装成一个对象,在adapter类中赋值。你的这种方法之前我同事也用过,我果断改了,而且布局文件的引用也不用这么麻烦
      

  5.   

    你的getView方法写的有问题  你先跟踪  能进getView方法再慢慢调试
      

  6.   

     List<Map<String, Object>> list = new ArrayList<Map<String, Object>>();有了这一句让你添加的数据成了局部变量list里面,你那个Adapter里面用的list是成员变量的list值都是空的哪来的数据?所以把它“List<Map<String, Object>> list = new ArrayList<Map<String, Object>>();”删了。想说的是你这弄得可是够乱的啊。看着都晕...定义变量乱套了都。
      

  7.   

    另外:
    private MyAdapter(Context context)
            {
              
                this.mInflater = LayoutInflater.from(context);
            }
    在这个构造方法里面再传个参数list.都没看清你那个adapter是不是放在activity中的