Changes

Jump to: navigation, search

Teams Winter 2011/team1/Android/Edit Contact

13 bytes added, 11:07, 7 April 2011
8. Edit Contact
=== 8. Edit Contact ===
'''8.1 Create Edit Layout '''<br/>
8.1.1 Add the String value for the layout title to String.xml:<br/> <source lang="java"> <string name="editContact_textView">Edit Contact</string> </source> 8.1.2 Right click on layout -> New -> Android XML File .<br/> 8.1.3 Enter edit.xml for the file name and check Layout:<br/> 8.1.4 Using Linear Layout, create this layout for editing contact information:<br/> [[Image: editContactLayout.png | 250px]]<br/> 8.1.5 Here is the edit.xml implementation: <source lang="java"> <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_height="match_parent"
android:orientation="vertical">
android:text="@string/saveButton" android:gravity="center_horizontal"
android:layout_gravity="center_horizontal" android:textSize="20dp"></Button>
</LinearLayout> </source>
'''8.2 Create EditContactActivity '''<br/> '''8.3 Add the EditContactActivity to the Android Manifest'''<br/> '''8.4 Implement The EditContact in the main activity class'''<br/> '''8.5 Edit Contact In action '''<br/>
[[Image: editMenuOption.png | 450px]]<br/>
[[Image: editView.png | 450px]]<br/>
[[Image: editViewEdited.png | 450px]]<br/>
[[Image: editViewSaved.png | 450px]]<br/>
1
edit

Navigation menu