I am developing the UI for one activity.In that activity I have added one scroll view .In that scroll view I have added one linear layout & in that linear layout I have added one edit text.Now I want to make that edit text as scrollable so how it will be possible?
            Asked
            
        
        
            Active
            
        
            Viewed 9,111 times
        
    1
            
            
        - 
                    You need to have enough controls in layout for the scroll bar to become active. Not sure with one edit text you can get it to scroll. – Wand Maker Jul 05 '13 at 14:34
3 Answers
3
            
            
        Try this code..
  // For horizontal scroll  
 android:scrollHorizontally="true"  
  //For vertical scroll
 android:scrollbars = "vertical"
 
    
    
        ridoy
        
- 6,274
- 2
- 29
- 60
 
    
    
        Benil Mathew
        
- 1,638
- 11
- 23
- 
                    try this *android:scrollbars = "vertical"* in your Edittext tag in xml – Benil Mathew Jul 05 '13 at 14:39
3
            
            
        You can't put a scrollview inside of a scrollview
<ScrollView
        android:id="@+id/scrollView1"
        android:layout_width="fill_parent"
        android:layout_height="100dp" >
        <EditText
            android:id="@+id/editText1"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:text="KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK" >
            <requestFocus />
        </EditText>
    </ScrollView>
 
    
    
        Guilherme Gregores
        
- 1,050
- 2
- 10
- 27
0
            
            
        From XML you can try with..
<EditText
    android:id ="@+id/editInput"
    android:layout_width ="0dip" 
    android:layout_height ="wrap_content" 
    android:layout_weight ="1" 
    android:inputType="textCapSentences|textMultiLine"
    android:maxLines ="4" 
    android:maxLength ="2000"   />
Else, follow these..
 
    