Android适配器视图读取Onclick项

Android适配器视图读取Onclick项,android,Android,我已经为android适配器视图上的ReadOnClick项编写了一个代码 String s = (lv.getItemAtPosition(position).toString()); 我正在传递它正在使用的信息 i.putExtra("myvalues", s); 在我的第二个类页面上显示如下输出: {description=关于选定内容的说明,title=选定内容} 我只是想知道如何分别显示描述和标题 例如: 所选标题(显示在一个文本视图上) 关于所选内容的说明(显示在另一个文本视图上

我已经为android适配器视图上的ReadOnClick项编写了一个代码

String s = (lv.getItemAtPosition(position).toString());
我正在传递它正在使用的信息

i.putExtra("myvalues", s);
在我的第二个类页面上显示如下输出:

{description=关于选定内容的说明,title=选定内容}

我只是想知道如何分别显示描述和标题

例如:

所选标题(显示在一个文本视图上) 关于所选内容的说明(显示在另一个文本视图上)

---一班------------

public void onItemClick(AdapterView父级、视图、, 内部位置,长id){

-----------------第二页------------------

我相信这个价值观:

TextView Textv = (TextView) findViewById(R.id.singleidview);
Intent iin = getIntent();
Bundle b = iin.getExtras();
if (b != null) {
    String j = (String) b.get("name");
    Textv.setText(j);
}

我想你是在谈论这个

       String parts[] = yourstring.split(",");

      parts[0] gives first string as description set this in first textview
       parts[1] gives your title set this in second textview

请再解释一下,向我们展示你的适配器。因此,在每一行的自定义布局中使用自定义适配器(如果你想在不同的文本视图中设置值,它们需要有两个文本视图)@MarkoNiciforovic所以,如何拆分{description=description about selected,title=selected title}两个文本视图的值,是否有比字符串部分[]=yourstring.split(“,”)更好的解决方案;感谢您的帮助,但是如果我们使用“,”部分[0]={description=description about selected.”进行拆分,这意味着它应该再次拆分以达到输出使用替换而不是下一步中的拆分意味着使用替换(“description=”,“”);这意味着用空白字符串替换字符串
       String parts[] = yourstring.split(",");

      parts[0] gives first string as description set this in first textview
       parts[1] gives your title set this in second textview