Ayda con codigo. gracias
Publicado por Juan (1 intervención) el 05/10/2005 11:32:34
Hola tengo este codigo que enlaza con un archivo de excell y me da error, este es el codigo:
import java.io.File;
import java.util.Date;
import jxl.*;
public class fra{
public static void main(String[] args){
Workbook libro = Workbook.getWorkbook(new File("myfile.xls"));
Sheet sheet =libro.getSheet(0);
Cell a1 = sheet.getCell(0,0);
Cell b2 = sheet.getCell(1,1);
Cell c2 = sheet.getCell(2,1);
String aa1 = a1.getContents();
String bb2 = b2.getContents();
String cc2 = c2.getContents();
System.out.print(aa1 + " " + bb2 + " " + cc2);
sheet.close();
libro.close();
}
}
Y me da error no reconoce ni CELL, WORKBOOK, Gracias
import java.io.File;
import java.util.Date;
import jxl.*;
public class fra{
public static void main(String[] args){
Workbook libro = Workbook.getWorkbook(new File("myfile.xls"));
Sheet sheet =libro.getSheet(0);
Cell a1 = sheet.getCell(0,0);
Cell b2 = sheet.getCell(1,1);
Cell c2 = sheet.getCell(2,1);
String aa1 = a1.getContents();
String bb2 = b2.getContents();
String cc2 = c2.getContents();
System.out.print(aa1 + " " + bb2 + " " + cc2);
sheet.close();
libro.close();
}
}
Y me da error no reconoce ni CELL, WORKBOOK, Gracias
Valora esta pregunta


0