解决方案 »

  1.   

    11-17 08:48:19.078: I/Choreographer(1488): Skipped 180 frames!  The application may be doing too much work on its main thread.
    11-17 08:48:19.178: D/dalvikvm(1488): GC_FOR_ALLOC freed 69K, 4% free 3008K/3132K, paused 49ms, total 53ms
    11-17 08:48:19.218: D/gralloc_goldfish(1488): Emulator without GPU emulation detected.
    11-17 08:48:19.368: I/Choreographer(1488): Skipped 47 frames!  The application may be doing too much work on its main thread.
    11-17 08:48:20.082: I/Choreographer(1488): Skipped 43 frames!  The application may be doing too much work on its main thread.
      

  2.   

    你的意图是不是按个按钮,然后根据文本框里的数字n动态添加n个新控件?
    如果是这样,那么我觉得下面的逻辑可能有问题:
    ----------------------------
    LayoutInflater inflater=getLayoutInflater();
    View view=inflater.inflate(R.layout.control,null);
    这两行是不是要放在循环的前面。
    -----------------------
    TextView tvCount=(TextView) view.findViewById(R.id.etCount);
    这里是不是应该是new 一个 textview,而不是findViewById
    -------------------------
    呵呵,我也是刚入门的新手,仅供参考。
      

  3.   

    首先,我要表示对你代码的不满意,真的不规范
    其次,我说说我的看法,根据你提供的日志显示是主线程阻塞了,为什么会阻塞,因为代码不规范,这种错误真的很不好表述
    最后,我把你的代码敲了一下,发现int count=Integer.parseInt(etCount.getText()+" ");这句有错误,看来你对java也不熟练,应该是int count = Integer.parseInt(String.valueOf(etCount.getText()).trim());你平白无故多加了一个空格,怎么转成整型?
      

  4.   

    是这句int count=Integer.parseInt(etCount.getText()+" ")有错误。
      

  5.   

    就是你们说的那个问题 我的JAVA 的确不是很好  谢谢了