Home Answers Viewqa Java-Beginners Exception when opening a excel file in JFrame

 
 


abdo
Exception when opening a excel file in JFrame
0 Answer(s)      9 months ago
Posted in : Java Beginners

Hello,

I have a problem when trying to display a Excel file in a Jframe. The exception is like this: com.jniwrapper.LibraryNotFoundException.

here is my code

public jexcelTest1() throws ExcelException{

        JFrame frame= new JFrame("Test application");
        frame.setDefaultCloseOperation
        (javax.swing.WindowConstants.EXIT_ON_CLOSE);
        Container cp = frame.getContentPane();
        cp.setLayout( new BorderLayout());
        JWorkbook workbook = new JWorkbook();
        cp.add(workbook);
        frame.setBounds(100, 100, 500, 500 );
        frame.setVisible(true);
    }

And the exception message is:

Exception in thread "main" com.jniwrapper.LibraryNotFoundException: Cannot find JNIWrapper native library (jniwrap.dll) in java.library.path: C:\Program Files\Java\jdk1.7.0_05\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Broadcom\Broadcom 802.11 Network Adapter\Driver;C:\Program Files\WIDCOMM\Bluetooth Software\;C:\Program Files\MiKTeX 2.9\miktex\bin\;C:\Program Files\Microsoft SQL Server\100\Tools\Binn\;C:\Program Files\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files\Java\jre7\bin;.

I already added the following libraries: comfyj-2.8.jar, jexcel-1.5.jar, jniwrap-3.8.2.jar, slf4j-api-1.5.8.jar, slf4j-simple-1.5.8.jar, winpack-3.8.2.jar

Can you clarify this for me please.

Abdousoft.

View Answers









Related Pages:
Exception when opening a excel file in JFrame
Exception when opening a excel file in JFrame  Hello, I have a problem when trying to display a Excel file in a Jframe. The exception is like...() throws ExcelException{ JFrame frame= new JFrame("Test application
retrieving excel data when file uploading
retrieving excel data when file uploading  <%@page import...); } } %> when i gave full path name i got excel data but when file...\\hp\\Desktop\\Book1.xls"; String filename=request.getParameter("excel
Help with opening a text file upon closing a program.
Help with opening a text file upon closing a program.  I need some... that is a swimming pool volume calculator. It stored that data on a output.txt file but I want that file to open whenever the user exits the program. My code so far
IllegalStateException for file opening
IllegalStateException for file opening  <%@page import...*"%> <%@include file="sessioncheck.jsp"%> <... = strtempfileName.substring(6, strtempfileName.length()); }catch(Exception e
IllegalStateException for file opening
IllegalStateException for file opening  <%@page import...*"%> <%@include file="sessioncheck.jsp"%> <... = strtempfileName.substring(6, strtempfileName.length()); }catch(Exception e
jframe
jframe  Create a JFrame for the Summervale Resort. Allow the user to view the information about different rooms available, dining options... information when the user makes a choice
excel
excel  how to read columns values of excel file in java and store...(value2); } i++; } }catch(Exception e...); list2.add(value2); } i++; } }catch(Exception e
Error Opening File - Java Interview Questions
. But when I try to export it under Runnbale jar file on my desktop and I run this generated file, a message was displayed: Error opening file. But If I...Error Opening File  Dear, Please if help me to resolve
"opening video data error" in j2me
"opening video data error" in j2me  Any one know about the error c When i am trying to play video on spice device its throw an exception... that and give the solution to handle this exception
How to read excel contents when uploaded
How to read excel contents when uploaded  I am working on a project where the user uploads his excel file. Jsp page must read the excel contents... files.Please do help..   user logins and he uploads his excel file. the excel
opening new window - Java Beginners
opening new window  Hi All, I have two classes with me , lets say... but the parent window is not disabled when the child(new) window is showing.The show() method... window.and also when child window is active, parent should be disabled. thanks
Convert CSV to excel File - Java Beginners
file. When trying to read from CSV, " Invalid header" exception is coming up...Convert CSV to excel File  Sir, i have CSV file as input. I need to convert that CSV file to excel file and format. Currently i am using HSSF POI
How to open excel sheet when excel file is placed in some folder in desktop
How to open excel sheet when excel file is placed in some folder in desktop  How to open an excel sheet using windows.open in IE... I am getting an error msg that the path is not correct.. But i have specified the correct path
JFRAME - Java Beginners
JFRAME  i am creating menu bar(file,edit) & in file am creating menuItems(new,open).. actionevent given to open(menuitem)... now when click on open... javax.swing.*; import java.awt.event.*; public class MenuExample extends JFrame
Access Excel file through JDBC
Access Excel file through JDBC In this section, you will learn how to access excel file through Jdbc and display records in JTable. As you know Excel comes... and the excel file. Here the name of the worksheet is equivalent to any database
Program to read the text from a file and display it on a JFrame.
Program to read the text from a file and display it on a JFrame.  ...*; class MegaViewer1 extends JFrame { JTabbedPane jtp1=new JTabbedPane... Exception { super("MegaViewer"); FileReader f=new FileReader
Excel file Handling in Java
Excel file Handling in Java  Hello Sir, I am new to Java, I have Started Java Core by myself. I want to make a project which include 3-4 Excel file to handle.Please explain how to read and write Excel file in Java.Is it tough
importing excel file
importing excel file  Hi All I am developing a java application whre we upload a excel file in to database and all excel value should import...); } cellVectorHolder.addElement(cellStoreVector); } } catch (Exception e
opening internet browser in java program - Swing AWT
opening internet browser in java program  i want a code to open the internet browser in swing program using JFrame.  Hi Omkar, Use...}); } } catch (Exception e
ODCB-EXCEL - Java Beginners
ODCB-EXCEL  Hi, i would like to extract data from an excel file. my excel file name is: TEST.xls the worksheet name is : qas i have configure... to extract the data of the excel file that has been stored into the database or you
Java and excel - JDBC
make the assumption that the client has Excel and // the file type .XLS... to a Jtable from where i can export to excel, i will like to format the column headers in excel using code. plz i nd help becos it is my project, as a serious student i
insert image in JFrame - Development process
); } static public void main(String args[]) throws Exception { JFrame frame... InputStreamReader(System.in)); String imageName=bf.readLine(); File input = new File(imageName); image = ImageIO.read(input); } catch
Linking an Excel File with the Application tool
Linking an Excel File with the Application tool  I have to link an excel file with a application software which I am developing.I have this code... on the questions that are in the excel file like extracting the questions from the excel file
opening new browser with new JSESSIONID using java
one IE browser and manually. And i ran my LaunchURL.java file, it is opening new...opening new browser with new JSESSIONID using java  I am facing...: java.awt.Desktop.getDesktop().browse() } catch (Exception ignore) { //library
java to excel connectivity - Swing AWT
Excel Driver(*.xls) 5. Select work book or excel file and Create the DSN name (e.g...java to excel connectivity  give me source code to stored the value... database on the excel.  Hi Friend, Follow these steps: 1. Open Data
Hiding a JFrame
and need not to access the behind one when I am using the first one. When I am... javax.swing.*; import java.awt.event.*; class PassData extends JFrame { JTextField... java.awt.*; import java.awt.event.*; class NextPage extends JFrame { NextPage
Hiding a JFrame
and need not to access the behind one when I am using the first one. When I am... javax.swing.*; import java.awt.event.*; class PassData extends JFrame { JTextField... java.awt.*; import java.awt.event.*; class NextPage extends JFrame { NextPage
Linking excel file with a application tool using swing
when we search for file to upload)and i should be able to select the excel file...Linking excel file with a application tool using swing  I have to link an excel file with my application software using java swing.As soon as i
excel
excel  how to save excel sheet data into the database using poi api...); } }catch (Exception e){e.printStackTrace(); } return cellVectorHolder...("Data is inserted"); stat.close(); con.close(); } catch(Exception e
How to save data to excel with a 2.1 work sheet format without changing it?
and save it to excel file then read it again .. the problem is , when data is saved , the extension file is changed to excel file with text ( tab limited...How to save data to excel with a 2.1 work sheet format without changing
Java file not found exception
Java file not found exception This section illustrates you the concept of file... by a code. When a file with the specified pathname does not exist, file not found exception will occur either by your code or by the JVM. File names are case
How to read a log file from server location and send a mail when exception occurs.
How to read a log file from server location and send a mail when exception occurs.  HI, How can i read the 2GB to 4GB log file from server. and i need to send a mail when exception occurs. Thanks Rajeev
Opening IE from Java Swing Application in Kiosk mode
(Exception e) { JOptionPane.showMessageDialog(null, "Error in opening browser" + ":\n...Opening IE from Java Swing Application in Kiosk mode  Hi All, I want... window is opening. But I want to open the IE window in Kiosk mode or without address
exception
exception  wHEN RUNTIME EXCEPTION CLASS IS SUB OF EXCEPTION CLASS HOW CAN'T HANDLE UNCHECKED EXCEPTION
how to display the excel file content in the jsp
how to display the excel file content in the jsp  How to present the content of the newly created excel file in the following jsp to the web browser...="application/vnd.ms-excel" %> <%@ page import="java.io.*" %> <
Java swing: Export excel sheet data to JTable
how to read data from excel file and export it to JTable. In swing applications, sometimes, it is required to display the excel file data into the jtable...()method which takes in an excel file and reads in the contents. The interfaces
Run time Exception after Clean and Build JavaNetBeans Project
The PROBLEM IS... When is run the jar file from the dist folder , the first form (i.e.... when i run the jar file form dist folder using cmdPrompt the following errors...Run time Exception after Clean and Build JavaNetBeans Project  I have
how to display the output of the newly created excel file
how to display the output of the newly created excel file  the following program will create the test.xlsx file, how can i display the content of the test.xlsx file in the web browser? thanks, %@ page import
how to display the excel file in the web browser.
how to display the excel file in the web browser.  > %@ page.../vnd.ms-excel" > %> <%@ page import="java.io.*" %> <% >... FileOutputStream > ("c:\\excel\\aqtemplate.xlsx"); > wb.write
retrieving of value from excel file - JSP-Servlet
this message to all the employees when i upload a file then it fetch a data from that excel sheet i.e this matter will take a para meter values from the excel...retrieving of value from excel file  Dear sir, Thanks for sending
retrieving of value from excel file - JSP-Servlet
this message to all the employees when i upload a file then it fetch a data from that excel sheet i.e this matter will take a para meter values from the excel...retrieving of value from excel file  Dear sir, Thanks for sending
Exception
Exception  whis is the Arithmetic Exception in java? or define Arithmetic Exception with exp?   Arithmetic Exception occurs, when you divide a number by zero. Example public class TryCatch { public static void main
reading data from excel file and plotting graph
reading data from excel file and plotting graph  I am doing a project using NetBeans in which i have to take input an excel file and then using the data in excel file, i have to plot graphs based on CELL ID selected. please help
Exception in thread
Exception in thread   Hi, I have created a java file for sending a file to my mail. I am using mail.jar file. I am able to create .class file properly. But am unable to run this file using java command on command prompt. javac
datetime picker is not opening
in this date time picker is not opening. The same opens in JSP code. My code... a date'></a>pick a date... "); } catch(Exception e) { out.println("Exception:"+e
exception
exception  Identify the reason for SQLException exception, which is encountered when the developer tries to run the following code snippet to insert..."); ps.executeUpdate(); } catch(Exception e
Create and Save Excel File in JSP
Create and Save Excel File in JSP  ... and saving Excel file from JSP application. In this example we are going... file.  To create an excel sheet we can use third party API which is Apache
connect jdbc to an Excel spreadsheet
to an Excel spreadsheet file using jdbc?   Hello Friend, Follow... Excel Driver(*.xls) Select work book or excel file and Create the DSN name (e.g...)); } } catch(Exception e){} } } Note: 'Excel sheet' is the sheet name
Java Exception
or if you want to build a program that could read a file with a specific name then you would be prompted to input a file name by the application. Then it passes the name to the constructor for java.io.FileReader and opens the file. However
Browse Excel File Problem - Development process
Browse Excel File Problem  I am using a web application,in which i have to browse an excel file columns. It is working in my system. But if i access... displayed when i browse the file. What is the problem?  Hi Friend

Ask Questions?

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.

Ask your questions, our development team will try to give answers to your questions.