Lab 4
This assignment relates to the following Course Learning Requirements:
• CLR 1: Write a graphical user interface-based program, given design documents. Techniques used will be object-oriented programming, structured programming, top-down coding, and event-driven coding.
• CLR 2: Produce tested code that executes correctly and consistently. Testing procedure will involve the use of iterative testing of GUI program components, valid data only, invalid data only, a combination of valid and invalid data and set wise refinement involving users.
• CLR 3: Prepare program documentation using prescribed program specifications.
• CLR 4: Debug program problems using manual and programmatic methods.
• CLR 5: Modify an existing program according to program specifications.
• CLR 6: Access and modify a database table from within the graphical user interface. Create a layered application (Presentation, Business, and Data access layers). Use a Data Access layer to provide data access to an application.
• CLR 7: Create GUI programs that support internationalization as well as sustainability.
• CLR 8: Collaborate with fellow students in a team to complete complex assignments.
Objective of this Assignment:
The following is an exercise to help you implement what you have learned in this module. It will allow you to familiarize yourself with the module content as well as practice the skills required to develop software in the Android Studio. The specific goal of this lab is to familiarize yourself with the ListView widget and creating a custom data adapter object to populate the ListView with data.
Pre-Assignment Instructions:
1. To prepare you for this assignment, please read the content presented in the associated module.
2. References:
a. http://www.vogella.com/tutorials/AndroidListView/article.html
b. https://www.javacodegeeks.com/2013/09/android-listview-with-adapter-example.html
c. https://www.tutlane.com/tutorial/android/android-alertdialog-with-examples
Assignment Tasks/Steps:
1. Make sure that you Create a branch of your software from Lab 3. Select the VCS menu in Android Studio and click “Git” -> “branches”. From the dialog box, select “New Branch” and call it “Lab 4”.
2. Add a button to the to your ProfileActivity from Lab 3. Set the text of the button to be: “Go to chat”. Set an onClick listener of the button to go to a new activity, called “ChatRoomActivity”. You can create the activity in AndroidStudio by selecting “File” -> “New” -> “Activity” -> “Empty Activity” and give it the name ChatRoomActivity.
3. You will need two drawable resources for the image view. Go to the website:
https://icons8.com/icon/set/avatar/all and find two png files that you want to have display in your list. Try and get the small version of the images, and rename them row_receive.png, and row_send.png. Drag them both into your drawable folder.
4. Design a layout that looks like this:
Students succeed in their courses by connecting and communicating with an expert until they receive help on their questions
Consult our trusted tutors.