Results 1 to 9 of 9
  1. #1
    Join Date
    Apr 2008
    Posts
    4
    Rep Power
    0

    Unhappy how to use JFrame in JSP ??

    please anyone tell me how can I call java frame in JSP.
    Actually I have made a program in frame displaying bar charts for records that are present in database. I want that a user enters an id from a JSP page and the bar chart of only those records will display having that id????
    please help me:(

  2. #2
    Java Tip's Avatar
    Java Tip is offline Moderator
    Join Date
    Nov 2007
    Posts
    1,694
    Blog Entries
    430
    Rep Power
    9

    Default

    You can not call jframe from jsp. You need to port your application to jsp or from jsp you will call an applet to show your charts. You can pass the chart parameter to the applet via a file on the server.
    "The sole cause of manís unhappiness is that he does not know how to stay quietly in his room." - Blaise Pascal

  3. #3
    sanjeevtarar's Avatar
    sanjeevtarar is offline Senior Member
    Join Date
    Apr 2008
    Location
    Jaipur(India)
    Posts
    318
    Rep Power
    7

    Default


    Ya priyanka you can only use applets in JSP/HTML.JFrame can not be included into Jsp.

    If you want to show charts in JFrame then just simply call then and show the output as popup window.


    sanjeev

  4. #4
    Join Date
    Apr 2008
    Posts
    4
    Rep Power
    0

    Default

    can u please tell me how can I do that? I do not have any idea about this. how can i show the output of my JFrame through applet?

  5. #5
    Join Date
    Apr 2008
    Posts
    4
    Rep Power
    0

    Default

    I can show the output as popup window but how can i pass value from my JSP/HTML form eg. user id to my JFrame so that the bars of only those records will be displayed having that id?? i think we can not we use getParameter etc. in JFrame.so what can be the alternative for this??

  6. #6
    sanjeevtarar's Avatar
    sanjeevtarar is offline Senior Member
    Join Date
    Apr 2008
    Location
    Jaipur(India)
    Posts
    318
    Rep Power
    7

    Default

    hello,


    Why do not you show your charts in Applet, in applet you can send and receive parameters from JSP/HTML.

    Is there any specific requirements to show charts in JFrame only..??


    sanjeev

  7. #7
    Join Date
    Apr 2008
    Posts
    4
    Rep Power
    0

    Default

    i have converted it into applet but now i m facing a new problem. my database connection is not getting open in applet while in jframe it was opening. i have used MS access as the database and when i m giving -
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    it is not proceeding and not executing any thing after it.
    after that i changed my dataabse to sql server 2005 and in this the connection is getting open but there is also a new problem occuring. i have used multiple result set . the updation is not taking place in the database due to multiple resulsets.

  8. #8
    vaishali is offline Member
    Join Date
    Nov 2008
    Posts
    1
    Rep Power
    0

    Default Hello

    Hello,to java forum

  9. #9
    Join Date
    Apr 2011
    Posts
    10
    Rep Power
    0

    Default

    Hey I also wanna ask?
    I'm developing a an online video game that sends info across the web through TCP. I want it to be in-browser. My problem is that its impossible to prevent the bad graphics when the applet is repeatedly blinking and flashing. If you know how to fix this or create a JFrame from a website or an applet it would be much appreciated.

Similar Threads

  1. Add an image to JFrame
    By Eranga in forum AWT / Swing
    Replies: 4
    Last Post: 02-01-2010, 03:09 PM
  2. JFrame problem
    By saytri in forum New To Java
    Replies: 6
    Last Post: 01-11-2008, 05:12 PM
  3. JFrame Question ?
    By Mindhunter74 in forum New To Java
    Replies: 2
    Last Post: 12-21-2007, 10:45 PM
  4. help me with JFrame and JLabel
    By michcio in forum New To Java
    Replies: 5
    Last Post: 11-20-2007, 07:44 AM
  5. Help with JFrame
    By Albert in forum AWT / Swing
    Replies: 2
    Last Post: 07-04-2007, 04:44 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •