変数名にインデックスを割り当てる方法は? たとえば、project0、project1、project2 など?
for (var i=0; i<data.length; i++)
{
var project+i = new GanttProjectInfo(1, "Applet redesign", new Date(2010, 5, 11));
var parentTask+i = new GanttTaskInfo(1, "Old code review", new Date(2010, 5, 11), 208, 50, "");
project1.addTask(parentTask+i);
// Load data structure
ganttChartControl.addProject(project+i);
// Build control on the page
}