안드로이드 개발 질문/답변
(글 수 45,052)
간단한 소스로는 이렇구요...
EditText et = new EditText(this);
et.setVerticalScrollBarEnabled(true);
et.setLayoutParams(new LayoutParams(
ViewGroup.LayoutParams.FILL_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT));
et.setVerticalFadingEdgeEnabled(false);
et.setScrollBarStyle(View.SCROLLBARS_INSIDE_OVERLAY);
et.setVerticalScrollBarEnabled(true);
et.setMinHeight(68);
et.setMaxLines(2);
LinearLayout root = (LinearLayout)findViewById(R.id.park); --> 요게 xml에 있는 메인 레이아웃입니다.
root.addView(et);
여러 방법 썻는데 맥스라인이 2줄을 넘어가도 스크롤바가 생기지 않네요;;; 스크롤은 되는데....
도움 부탁합니다....