I was wondering how you could make the TextView and EditText run in sequence so that I wouldn't need one row for the TextView and another for the EditView. I just feel it would make the app i'm creating a lot more clean. Any advice on that.
So far I'd connected the EditText to a button which then outputs text.I simply just want it in one row. This is the code I have so far.
public class EventActivity extends AppCompatActivity {
private EditText enter_txt;
private TextView txt_title;
public void buttonOnClick(View v) {
Button button = (Button) v;
enter_txt = (EditText) findViewById(R.id.enter_txt);
txt_title = (TextView) findViewById(R.id.txt_title);
txt_title.setText(enter_txt.getText());
}
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_event);
}
}
Here's a picture of what I've got so far. Thanks. :D