A. Draw 3 big rectangle.. 2 for the graphs and 1 for the components..
First rectangle codes :
g.DrawRectangle( pen, 100, 50, 300, 500 );
This means that the rectangle will start at pixel (100,50) and have 300 pixels width, 500 pixels height..
g.DrawRectangle( pen, 525, 50, 300, 500 ); for second graph
g.DrawRectangle( pen, 850, 50, 150, 400 ); for components box
B. Write Title
Write "Schedule for Production Line" at the top of the window..
g.DrawString( "Schedule for Production Line", arial, brush, 300, 10 );
C. Vertical hash marks
Draw 9 vertical hash marks for the 2 graphs..
g.DrawLine( pen, 130, 50, 130, 550 );
g.DrawLine( pen, 160, 50, 160, 550 );
g.DrawLine( pen, 190, 50, 190, 550 );
g.DrawLine( pen, 220, 50, 220, 550 );
g.DrawLine( pen, 250, 50, 250, 550 );
g.DrawLine( pen, 280, 50, 280, 550 );
g.DrawLine( pen, 310, 50, 310, 550 );
g.DrawLine( pen, 340, 50, 340, 550 );
g.DrawLine( pen, 370, 50, 370, 550 );
These codes are for the 1st graph.. A straight line will be drawn from pixel (130,50) to pixel (130,550) after the 1st line of the codes executed..
Second graph codes :
g.DrawLine( pen, 555, 50, 555, 550 );
g.DrawLine( pen, 585, 50, 585, 550 );
g.DrawLine( pen, 615, 50, 615, 550 );
g.DrawLine( pen, 645, 50, 645, 550 );
g.DrawLine( pen, 675, 50, 675, 550 );
g.DrawLine( pen, 705, 50, 705, 550 );
g.DrawLine( pen, 735, 50, 735, 550 );
g.DrawLine( pen, 765, 50, 765, 550 );
g.DrawLine( pen, 795, 50, 795, 550 );
D. Write "Time (Hours)"
Write "Time (Hours)" at the bottom of both graphs..
g.DrawString( "TIME (HOURS)", arial2, brush, 205, 575 );
g.DrawString( "TIME (HOURS)", arial2, brush, 630, 575 );
E. Write "Component"
Write "Component" in the 3rd rectangle..
g.DrawString( "COMPONENTS", arial2, brush, 870, 60 );
F. Write "Equipment"
Write "Equipment" at the left of both graphs..
g.DrawString( "E", arial2, brush, 15, 200 );
g.DrawString( "Q", arial2, brush, 15, 220 );
g.DrawString( "U", arial2, brush, 15, 240 );
g.DrawString( "I", arial2, brush, 15, 260 );
g.DrawString( "P", arial2, brush, 15, 280 );
g.DrawString( "M", arial2, brush, 15, 300 );
g.DrawString( "E", arial2, brush, 15, 320 );
g.DrawString( "N", arial2, brush, 15, 340 );
g.DrawString( "T", arial2, brush, 15, 360 );
g.DrawString( "E", arial2, brush, 440, 200 );
g.DrawString( "Q", arial2, brush, 440, 220 );
g.DrawString( "U", arial2, brush, 440, 240 );
g.DrawString( "I", arial2, brush, 440, 260 );
g.DrawString( "P", arial2, brush, 440, 280 );
g.DrawString( "M", arial2, brush, 440, 300 );
g.DrawString( "E", arial2, brush, 440, 320 );
g.DrawString( "N", arial2, brush, 440, 340 );
g.DrawString( "T", arial2, brush, 440, 360 );
G. Write "Total Processing Time"
Draw two "Total Processing Time" labels at the bottom of the screen
g.DrawString( "TOTAL PROCESS TIME", arial2, brush, 160, 625 );
g.DrawString( "TOTAL PROCESS TIME", arial2, brush, 585, 625 );
Subscribe to:
Post Comments (Atom)
1 comment:
o0o..need to design dynamic gantt chart..susah gak ek..btul ke aku eje "gantt chart"..hehe..kantoi bodo je aku ari tu..
Post a Comment