Android - Problem in Edittext

Posted by PM - Paresh Mayani on Stack Overflow See other posts from Stack Overflow or by PM - Paresh Mayani
Published on 2011-01-12T07:49:53Z Indexed on 2011/01/12 7:53 UTC
Read the original article Hit count: 435

Filed under:
|

Hi,

I am facing trouble to set WrapText kind of facility in EditText.

Problem: When i try tp enter data in EditText, it goes beyond the screen width (scrolling horizontally). Instead of it should be appear in next-line.

Please suggest me what should i do ??

Please have a look at below image:

alt text

I have done the below XML coding:

<TableLayout 
    android:layout_width="fill_parent"  
    android:layout_height="fill_parent"
    android:paddingTop="10dp"
    android:paddingLeft="10dp"
    android:paddingRight="10dp"
    android:stretchColumns="1">

    <TableRow android:id="@+id/TableRow02" android:layout_width="fill_parent" android:layout_height="wrap_content">
        <TextView 
            android:text="Name:" 
            android:id="@+id/TextView01" 
            android:layout_width="80dp" 
            android:layout_height="wrap_content"
            android:textSize="16dip">
        </TextView>
        <EditText 
            android:id="@+id/txtViewName" 
            android:layout_height="wrap_content" 
            android:layout_width="wrap_content"
            android:inputType="textFilter|textMultiLine|textNoSuggestions"
            android:scrollHorizontally="false">
        </EditText>
    </TableRow>
</TableLayout>

© Stack Overflow or respective owner

Related posts about android

Related posts about android-edittext