@Override
    public void mouseClicked(MouseEvent e) {
          
            CreateReport cr = new CreateReport();
        
            if(index==1){try {
                cr.CreatePDF(file);
                System.out.println("The PDF report has created successfully!");
            } catch (Exception ex) {}
        }
            
            else if (index ==2){
            try {
                cr.CreateXML(file);
                System.out.println("The XML report has created successfully!");
            } catch (Exception ex) {}
        } 
            
            else if (index ==3){
            try {
                cr.CreateHTML(file);
                System.out.println("The HTML report has created successfully!");   
            } catch (Exception ex){}
         }
            
    }