Perforce JViews Gantt Sample: Resource Chart (SDK)


Description

This sample shows a simple project scheduling application displayed as a resource-oriented Schedule Chart.

How to Use the Sample

How to Run the Sample as an Application

This sample can be run as an application. The installation directory contains an executable JAR file, schedule-chart.jar, that allows you to execute the sample with a double click from a file browser. Note that if you are using Internet Explorer, you can open the installation directory and execute the JAR file from the browser. This technique may not work in other Web browsers.

Alternatively, you can run the sample application from the command line. First check that the Ant utility is properly configured. If not, see the instructions on how to configure Ant for Perforce JViews.

Then, go to the installation directory of the sample and type:

ant run

Topics Covered

Detailed Description

This sample shows a simple project scheduling application displayed as a resource-oriented Schedule Chart.

Selecting Resources and Reservations

Many operations on the Schedule Chart apply to resources and reservations selected by the user.

Editing Resource Properties with the Table

The resource table is fully editable. Change the properties of a resource by typing in the corresponding table cells.

Interacting with the Gantt Sheet

You can interact with the Gantt sheet in the following ways:

Zooming and Scrolling in the Time Scale

You can zoom and scroll in the time scale:

Scrolling in the Table

You can use the up and down arrow keys, or the page up and page down keys, to scroll up and down the table.

Editing Resources

Creating and Deleting Resources

To create a new resource:

  1. Select an existing resource to indicate where the resource should be created.
  2. Choose Insert resource from the Edit menu.

To delete an existing resource:

  1. Select the resource to be deleted.
  2. Choose Delete resource from the Edit menu.

Moving a Resource in the Table

To change the hierarchical position of a resource:

  1. Select the resource to be moved.
  2. ChooseIndent resource,Outdent resource, Move up, or Move down from the Edit menu.

Creating and Deleting Reservations

To create a reservation:

  1. Select Create reservation from the Edit menu.
  2. In the Gantt sheet, click on the row where the reservation should be created.
  3. Drag the mouse to create the reservation.

Changing the Property Displayed in the Reservation Graphics

In the Gantt sheet, reservation graphics show the positions of the reservations as time span rectangles. They can also show some properties of the displayed reservations.

The Field menu allows you to choose the property you want to display in the reservation graphics. To do so:

  1. Select a reservation.
  2. Choose the field you want displayed from the Field menu.

Changing the Row Height of the Schedule Chart

The Schedule chart consists of resource rows. The height of the rows can be changed. The Row menu lists a number of commands that allow you to increase or decrease the row height of the Schedule chart.

Changing the Activity Layout

A resource may have more than one reservation shown in the same row of the Gantt sheet. The relative vertical positions of the reservations are managed by the activity layout of the Schedule chart to avoid potential overlapping activities.

To choose from different activity layouts for the Schedule chart, use the commands in the Row menu.

Installation Directory

The Resource Chart (SDK) sample is installed here.

Classes Involved

Source Files

Copyright © 2021 Rogue Wave Software, Inc., a Perforce company. All rights reserved. Legal terms.