Presentation is loading. Please wait.

Presentation is loading. Please wait.

Lab 0 Objectives Input a basic Java Program Learn the basics of VisualAge.

Similar presentations


Presentation on theme: "Lab 0 Objectives Input a basic Java Program Learn the basics of VisualAge."— Presentation transcript:

1 Lab 0 Objectives Input a basic Java Program Learn the basics of VisualAge

2 Requirements: Build a Welcome Applet equivalent to the one described below using the tools of VisualAge. Import code for the applet in fig3.10 – you can find this in the shared directory. Learn how to clean up. VisualAge is a shared repository and you MUST not leave your code behind for the next student.

3 Open VisualAge Under Selected Choose Add and then Project... Part 1

4 In the SmartGuide Choose Create a new project Name it, say, Project1 Click Finish

5 With Project1 highlighted Under Selected Choose Add and then Package...

6 In the SmartGuide Choose Create a new package Name it, say, welcome Click Finish

7 With welcome highlighted Under Selected Choose Add and then Applet...

8 In the SmartGuide Add an Applet name, WelcomeApplet Click Japplet Uncheck Compose the class … Click Finish

9 Here is the Class Browser in Source mode (1st tab). Note that VisualAge has added the stubs of member functions for you.

10 Click the Members tab; Click function paint(Graphics); Replace the code place holder with the g.drawString(…) code above.

11 Click on any other function; click Yes in the text modified popup.

12 Go back to the Workbench window. Highlight WelcomeApplet Right click and choose Run and then In Applet Viewer

13

14 Part 2 Copy the fig03_10 folder to your U: drive In the Workbench highlight Project1 Choose File and then Import from a directory

15 In the SmartGuide Browse to the fig03_10 directory.java and resource should be checked Click Details and OK Click Finish

16 Note that a Default package for Project1 has been added. Highlight WelcomeLines Run as before.

17

18 Part 3: Cleanup First export your work. In the Workbench under File choose Export and then directory In the SmartGuide Browse to the folder you want this stored in Click Finish

19 In the Workbench, highlight Project1 Right click and choose Delete... Delete your project.

20 In the Workbench Under Window Choose Repository Explorer

21 In Repository Explorer Click the Projects tab Scroll to Project1 Right click and Choose Purge... Purge your project


Download ppt "Lab 0 Objectives Input a basic Java Program Learn the basics of VisualAge."

Similar presentations


Ads by Google