the adapter does work? : **i get the input from the user and set them in a list view but when i click in the button does work NO Errors just open the layout and close direct but when a try with "arrayAdapter = new ArrayAdapter<String>(this,android.R.layout.simple_list_item_1,m_list);" is work perfect can you please tell me where im wrong 
thank you 
im New in Android**

    public class HomeChat extends AppCompatActivity {
    
        ListView listView;
        EditText writeSms;
    
        ArrayAdapter<String> arrayAdapter;
        ArrayList<String>  m_list = new ArrayList<String>();
        String emriUser;
    
        @Override
        protected void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            setContentView(R.layout.activity_home_chat);
    
            writeSms = (EditText) findViewById(R.id.shkrunSms);
            listView = (ListView) findViewById(R.id.listView);
    
    
            emriUser = getIntent().getExtras().getString("emri");
    
            arrayAdapter = new ArrayAdapter<String>(this,R.layout.list_chat,m_list);
            listView.setAdapter(arrayAdapter);
    
        }
    
    
        public void sentSmsButton(View view) {
    
          String  mesazhet = emriUser + ": " + writeSms.getText().toString();
    
            if (writeSms != null && writeSms.length() > 0) {
    
                m_list.add(mesazhet);
                arrayAdapter.notifyDataSetChanged();
                writeSms.setText("");
    
            }else
            {
                Toast.makeText(getApplicationContext(),"Something Wrong",Toast.LENGTH_LONG).show();
            }
        }
    }


 **and this is the list chat layout**

    <?xml version="1.0" encoding="utf-8"?>
    <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
        android:orientation="vertical" android:layout_width="match_parent"
        android:layout_height="match_parent">
    
        <TextView
            android:id="@+id/test123"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:textColor="#000"
            android:background="#cccccc"
            android:paddingTop="5dp"
            android:paddingBottom="5dp"
            android:paddingLeft="5dp"
            android:paddingRight="5dp"
            />
    
    </LinearLayout>

