frames[index].setTitle(frames[index].getTitle() + " " + d);
int id = ((MyInternalFrame)frames[index]).getInternalId(); frames[index].setTitle("#" + id + " " + d);
                  public void run() {                     JInternalFrame[] frames = desktop.getAllFrames();                     frames[index].setTitle(frames[index].getTitle() + " " + d);                  }