How can i import my classes in jsp?

Dear All,
i want to access my classes in jsp. i am using apache tomcat
server. let me know where i have to put my own packages and
how can i use them in jsp.
thanks

Put them in directory /WEB-INF/classes under you webcontext. You can use them in your jsp by importing them or using the useBean directive.

Similar Messages

  • How can I import a class in my program?

    In my program I want to use a class named "WordExtractor" that resides in a jar file named "poi-3.0.1-FINAL-20070705.jar".
    This jar file is stored on my computer under:
    D:\java_projects\Word Reader\poi-bin-3.0.1-FINAL-20070705\poi-3.0.1-FINAL\poi-3.0.1-FINAL-20070705.jar
    How can I import this class WordExtractor into my program?
    import ????????? ;

    In my program I want to use a class named
    "WordExtractor" that resides in a jar file named
    "poi-3.0.1-FINAL-20070705.jar".
    This jar file is stored on my computer under:
    D:\java_projects\Word
    Reader\poi-bin-3.0.1-FINAL-20070705\poi-3.0.1-FINAL\po
    i-3.0.1-FINAL-20070705.jar
    How can I import this class WordExtractor into my
    program?
    import ????????? ;After you add this jar file to the lib , you can use a tools(rar extracter tools) to extract "poi-3.0.1-FINAL-20070705.jar" file and find the position of that class "WordExtractor" .
    write "import XXXX.WordExtractor"into your program,"XXXX" is the position that you have found.

  • How can I import my class or package in JSP?

    Hello.
    I develop jsp. When I assign variables in jsp, everything work fine. For Example:
    connStr="jdbc:oracle:thin:@191.168.0.1:1521:orcl";
    But I want put some variables inside class or package, so using text editor I created and compiled package:
    package Pack1;
    public class Test1 extends java.lang.Object {
    public static void main(String[] args) {
    String ConnStr = "jdbc:oracle:thin:@191.168.0.1:1521:orcl";
    or class
    class Test1 {
    public static void main(String[] args) {
    String connStr = "jdbc:oracle:thin:@191.168.0.1:1521:orcl";
    But as soon as I put in my jsp line
    <%@ page import="Test1" %> or <%@ page import="Pack1.*" %>
    I always have an error.
    JSP Error:
    Request URI:/DateN/search/Search.jsp
    Exception:
    oracle.jsp.provider.JspCompileException:
    Errors compiling:e:\orant\oem8i\apache\apache\htdocs\daten\_pages\_daten\_search\_Search.java
    C:\orant\oem8i\apache\apache\htdocs\daten\_pages\_daten\_search\_Search.java:12: Package DateN not found in import.
    import Pack1.*; (or Test1)
    ^
    1 error
    I using OEM2.2 with Apache-Server under Win2000. I put my classes:
    Test1 in package: in folder: C:\orant\oem8i\Apache\Apache\htdocs\WEB-INF\classes\Pack1
    If just class, when just in folder: C:\orant\oem8i\Apache\Apache\htdocs\WEB-INF\classes
    If I using just class, when I put just in folder: C:\orant\oem8i\Apache\Apache\htdocs\WEB-INF\classes.
    Im stack. Anybody can help?
    Thank you.

    Another way. You can use a USB flash drive & the camera connection kit.
    Plug the USB flash drive into your computer & create a new folder titled DCIM. Then put your movie/photo files into the folder. The files must have a filename with exactly 8 characters long (no spaces) plus the file extension (i.e., my-movie.mov; DSCN0164.jpg).
    Now plug the flash drive into the iPad using the camera connection kit. Open the Photos app, the movie/photo files should appear & you can import. (You can not export using the camera connection kit.)
    Secrets of the iPad Camera Connection Kit
    http://howto.cnet.com/8301-11310_39-57401068-285/secrets-of-the-ipad-camera-conn ection-kit/
     Cheers, Tom

  • How can I creat a folder by jsp

    import java.io.*;
    class folder
         public static void main(String args[])
              folder foIns = new folder();
              foIns.makeDir("E:\\test");
         public static void makeDir(String dir)
    File d = new File(dir);
    if (!d.exists()) {
    d.mkdir();
    I can creat a folder by java , but how can I creat a folder by jsp??
    thanks all ^_^

    import java.io.*;
    class folder
         public static void main(String args[])
              folder foIns = new folder();
              foIns.makeDir("E:\\test");
         public static void makeDir(String dir)
    File d = new File(dir);
    if (!d.exists()) {
    d.mkdir();
    I can creat a folder by java , but how can I creat a
    folder by jsp??
    thanks all place this class file in web-inf/classes of your web application,and in jsp page use
    <jsp:useBean id="fold" class="your complete class name" scope="page"/>
    <%
    fold.makeDir("dir name");
    %>

  • How can I hide the class file ??

    Hi !
    I has a question, when i write a program of Java, then use the command "javac" to compiler to class file for other people using, but the class file can be disassembled and convert to source code. How can I hide the class file and let people can not disassemble, or can not see the source code. Thinks

    See these....
    http://www.saffeine.com/
    http://www.jarsafe.com/
    I recently read this. This will help you.
    http://developer.java.sun.com/developer/qow/archive/160/index.jsp
    Enojy....
    Rajesh

  • Import, import, import... but how can i import my own libraries?

    This is the case: i have a personal library, made by me. I jarred it and then i put it on a subdirectory named lib.
    How can i import it on a new class file? Because import only loads libraries on the jdk directory and only in the format any.any.* Compile is not the problem, i set up classpath and no problem. But if i send my program to another person, it wont run because dont have the library.
    And another question: can i put all the libraries in a jar file and the program read libraries IN the jar? So, how do i import it?

    How can i import it on a new class file? Because
    import only loads libraries on the jdk directory and
    only in the format any.any.*Bad assumption. It will import anything in the classpath.
    Compile is not the
    problem, i set up classpath and no problem. But if i
    send my program to another person, it wont run because
    dont have the library. Well, gee, they need the jar too, don't they?
    >
    And another question: can i put all the libraries in a
    jar file and the program read libraries IN the jar?
    So, how do i import it?Jars cannot contain (ok, they can, but not without a custom classloader) other jars.

  • How can I import file of photos from external drive into photoshop elements 11 organizer?

    I just started with elements 11 after many years of El., 10. How can I import files from external disk to elements 11 organizer? My files were stored on the external drive.

    Hi,
    The Canon S100 wasn't supported until version 6.6 of camera raw and that isn't supported by pse 8.
    You options are to either upgrade to pse version 10 or use the DNG converter
    for windows http://www.adobe.com/support/downloads/detail.jsp?ftpID=5310
    or
    for mac http://www.adobe.com/support/downloads/detail.jsp?ftpID=5309
    Brian

  • How can I import a  library ??

    How can use the WSDP library of inside Java SDK? I want to use the javax.servlet class but it is not available in SDK, however it is available in WSDP .How can I import them into Java1.4.1 Applications ?
    2nd:I have already set JAVA_HOME & ANT_HOME as permenant Environment Variables .the ant build command gives me a message that the setenv.bat is not recognized .
    The problem is that setenv.batch is in another directory of the ANT_HOME's and I don't know what variable I should use to point to it.

    What classes in particular are you wanting to use? If they're sitting there as jars on your box -- add them to your classpath when you compile/execute and all should be well.
    Some of these classes will most likely have dependencies upon classes associated with the J2EE platform (considering that a good deal of them are fashioned to execute inside of some form of servlet container) -- so, it's a wise idea to go ahead and grab the J2EE SDK as well.
    And, people do care, they just don't care for someone that nags.

  • How can i import the AUC value when the project go-live

    Dear all experts,
    please help me on the following issue.
    our SAP project will go live in Jan 2010.
    there are some open investment projects to be imported in the PRD.
    the projects are settled to AUC when it is not completed.
    so the actual cost of open projects are the value of AUC.
    but i can not use AS91 to import the value for the AUC because the asset class is for investment measure.
    so  i want to know how can i import the value to AUC thanks a lot.

    Dear  Judy ZHU,
    You can do manual posting to FI using T code like FB50,
    Dr - Cost element(related to project cost ) & WBS
    Cr- CWIP account.
    After that run CJ88 for that project, your project expenses will be settled into AUC/Cost center.
    This is one proposed solution for this to my knowledge..
    SAP experts,  Please correct this if i'm wrong, since I' have not  practically used this method.
    Regards,
    Sam L.

  • How can i import contacts from another AIM account to this new one

    If you reference my last ichat question, you will see that I have had serious problems and had to create a new account.
    How can I import contacts from another AIM account to this new one??

    Hi,
    Use AIM for Mac and use the Export and Import features.
    Other than that it is a question on making sure every Single Buddy has more than just their Screen name in the IChat Address Card so it is added to the Address Book and dragging them back from there
    9:08 PM Thursday; February 7, 2008

  • Not enough space on my new SSD drive to import my data from time machine backup, how can I import my latest backup minus some big files?

    I just got a new 256GB SSD drive for my mac, I want to import my data from time machine backup, but its larger than 256GB since it used to be on my old optical drive. How can I import my latest backup keeping out some big files on the external drive?

    Hello Salemr,
    When you restore from a Time Machine back up, you can tell it to not transfer folders like Desktop, Documents. Downloads, Movies, Music, Pictures and Public. Take a look at the article below for the steps to restore from your back up.  
    Move your data to a new Mac
    http://support.apple.com/en-us/ht5872
    Regards,
    -Norm G. 

  • How can I convert a class file to Exe file

    hai
    How can I convert a class file to Exe file

    Please search the forums before asking questions - this has been answered hundreds (really!) of times.

  • How can I import data in to the digital word generator in Multisim?

    How can I import data in to the digital word generator in Multisim?
    I just  received this comment from a friend, a RADAR engineer, who has just down loaded Multisim.  He has been using HP/Agilent software.  He has a work around using a piecewise linear voltage waveform with data imported from Excel but this is not really a good solution.  It would also be helpful to import data from Mathcad or equivalent.
    "I thought I was about to be impressed with MultiSim but it ended only in disappointment. There is a word generator in the simulation instrument panel which can drive the DAC with a waveform and it can have thousands of lines of values. I opened Excel, wrote the formula to generate the time and voltage points for a chirp, converted to DAC values in Hex and then went back to the word generator in MultiSim to load the values only to find that you have to enter each value manually. It doesn’t even allow you to paste in a list of values from a text file. I’m not going to type 5000 values by hand. If you get the chance to give feedback to National Instruments please ask them if the paste option can be added to the word generator. MultiSim is useful in many regards, but in this case, it left me with the impression that it is considerably limited in capability compared to what I’m used to."

    Hi,
    You can load your data automatically in the Multisim word generator. Follow these steps:
    - Save your data file (in excel .xslx ir .csv format) on your computer
    - Change the extension of the file to ".dp"
    - Double-click the word generator in Multisim and click on Set...
    - In the Settings dialog box, click on Load and then Accept
    - This will prompt you to select the .dp file you have on your computer, select it and you're good to go
    However, in Multisim you have the option of creating your own custom simulation analysis and instrument.
    I will try creating the instrument and send it back to you but it might take some time.
    Multisim and LabVIEW are very powerful in test automation, with the custom instruments you create for Multisim you don't need to export your data file into excel from LabVIEW (or MathCAD or other tools) and then reload it into Multisim. The test procedure is automated instead.
    Please check this reference design about automated simulation
    http://zone.ni.com/devzone/cda/tut/p/id/7825
    Here is how you can create your own custom measurement tool in Multisim and LabVIEW, but as I mentioned, I will create the word generator and come back to you anyways
    http://zone.ni.com/devzone/cda/tut/p/id/5635
    Let me know if you have any questions.
    Mahmoud W
    National Instruments

  • How can I import songs which are filed basis one album/compilation as one folder?

    How can I import songs which are filed basis one album/compilation as one folder?
    i can drag and drop one folder which is a proper album into itunes under playlist. if i drag and drop two proper albums into itunes it is also ok but if itunes does not know my own compliations and i drag and rop my 3000 folders in one shot into itunes i get only one playlist containing all songs.
    pleased to hear if anybody know how i can avoid to do 3000 times drag and drop a folder into itunes.
    rgds, alexander

    Before you begin the import, edit the properties of the tracks to set the Album Artist to Various Artists and Part of a Compilation to Yes.
    For more info. see Grouping tracks into albums.
    tt2

  • How can I import pictures from my iphone to PC which I imported to the iphone from another PC? The folder doesn't show on my computer. I see all other pictures I took with the phone but not the imported folder.

    How can I import pictures from my iphone to PC which I imported to the iphone from another PC? The folder doesn't show on my computer. I see all other pictures I took with the phone but not the imported folder.

    Photos that were synced from a computer won't show for copying to a computer. If you want to copy them back then you will need a third-party app on your phone such as Simple Transfer which can copy them off via your wifi network. But photos are 'optimised' when they are synced to a device, any that you then copy back to a computer may not be exactly the same as they originally were on your computer (e.g. their dimensions might be different and their colours may look a bit different).

Maybe you are looking for