Results 1 to 13 of 13

Thread: New Java member

  1. #1

    Thread Starter
    New Member
    Join Date
    Jul 2003
    Location
    Malaysia
    Posts
    6

    Question New Java member

    Hi all


    May i know what is the different between JDK and JBuiler, because i'm using the JBuiler currently and want to know about JDK, is it the same thing, mean even the interface also same as Jbuiler?





    Thank...
    Allen

  2. #2
    Dazed Member
    Join Date
    Oct 1999
    Location
    Ridgefield Park, NJ
    Posts
    3,418
    JBuilder is an IDE. The jdk contains the API and the runtime. You could load JBuilder with the J2ME and just program with that if you wanted to.

  3. #3

    Thread Starter
    New Member
    Join Date
    Jul 2003
    Location
    Malaysia
    Posts
    6

    Question

    Can you show me the steps of creating an application(Using JBuiled). When we create an application in Java:

    1. Type the code in Textpad
    2. Save it with (xxx.java)
    3. Compile it
    4. Run

    DOES ABOVE CORRECT?


    I'M USING JBuiler, WHEN I'D COMPILED AND RUN THE APPLICATION, I SELECT TO SAVE ALL. IS IT THE FINAL FORM OF MY APPLICATION IS in xxxx.exe?

    SO, I CAN RUN IT AT ANY PLACE? HOW IF I UNINSTALL THE JBuiler, CAN THE APPLICATION THAT I SAVED BEFORE RUN WITHOUT JBuiler??



    Thank...
    Allen

  4. #4

    Thread Starter
    New Member
    Join Date
    Jul 2003
    Location
    Malaysia
    Posts
    6

    Question

    I have learned C/C++ before, as what i knew about C/C++, when we create an application, let say " course.c " after we completed the source codes then we save it as " course.c "

    Second step we compiled it by using C compiler. the "course.c" will changed to " course.exe ".

    We can only copy the " course.exe " to another computer and click on it, it will execute as normal.



    BUT FOR " java ", I HAVE NO IDEA ABOUT HOW THE THING WORKS. LET SAY WE CREATE A SOURCE CODE CALLED " course.java ", THEN HOW THE "course.java " WILL CHANGE IN NEXT STAGE? HOW TO COMPILE IT? HOW IF IT BEING COPIED TO OTHER COMPUTER, IS IT WORK WELL?




    Hope can get some help




    Thank you
    Allen

  5. #5
    Dazed Member
    Join Date
    Oct 1999
    Location
    Ridgefield Park, NJ
    Posts
    3,418
    As long as the runtime is installed on the system you can execute any .class files.The .java file does not change into an .exe. Upon compliation a .class file will be created which will contain the java byte code. After compiling your .java file you will end up having two files one .java and one .class.

  6. #6

    Thread Starter
    New Member
    Join Date
    Jul 2003
    Location
    Malaysia
    Posts
    6
    Firstly, thank you so much for your help As what i know now about Java is we need to create a source code and save it as " Test.java " (Example)


    MY QUESTION IS WHERE WE NEED TO SAVE OUR SOURCE CODE? IS IT SAME DIRECTORY WITH JAVA? MEAN IF THE JAVA DIRECTORY IS c:\java, CAN OUR SOURCE CODE SAVE AS c:\java\new\Test.java (New folder called new) OR CAN WE SAVE IT IN DIFFERENT DIRECTORY? HOW THE COMPILER CAN FIND IT? IF SO, PLEASE SHOW ME THE STEPS.

    I"D TRY TO TYPE " javac Test.java" IN DOS MODE, BUT IT SHOW " bad command and error" WHY?


    IF IN NEXT TIME WE WANT TO EXECUTE THE "Test.java" IS IT WE NEED TO CLICK ON THE " Test.class ONLY?


    HOW TO SENT OUR EXECUTABLE APPLICATION TO OTHER COMPUTER? WHICH FILE NEED TO SENT? Test.java OR Test.class? CAN THIER COMPUTER EXECUTE OUR APPLICATION? HOW?


    WHAT IS JAVA RUNTIMES?

    Thank you
    Allen

  7. #7

  8. #8

    Thread Starter
    New Member
    Join Date
    Jul 2003
    Location
    Malaysia
    Posts
    6
    May i know how to create a java program with the below requirements:


    1. gui mode
    2. Need to key in and store data- database ( both text and number)




    Can you let me know what the items need to include in the source code?

    Please give some example codes




    Thank you
    Allen

  9. #9
    Dazed Member
    Join Date
    Oct 1999
    Location
    Ridgefield Park, NJ
    Posts
    3,418
    That's quite a lot to ask for. For the gui you would have to import java.awt.*, javax.swing.*; and for any events you would have to import java.awt.event.*; for any database stuff you should check out the JDBC on suns site to get more information. I would suggest using the forums that are on suns site in addition to this forum.

  10. #10
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    java.sun.com has some excellent Java tutorials. Including GUI.

    And please, could you refrain from using all-caps in posts? It's tiresome to read. Thanks.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  11. #11

    Thread Starter
    New Member
    Join Date
    Jul 2003
    Location
    Malaysia
    Posts
    6
    What are the methods except the JDBC used to store data? is it ObjectInputStream and ObjectOutputStream, how to use?








    Thank you
    Allen

  12. #12
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    Reader and Writer-derived classes for reading/writing text to storages (such as files), InputStream and OutputStream-derived classes for binary data.

    ObjectInputStream and ObjectOutputStream convert your classes to a binary storage form and back.

    Then there's something in java.util for storing preferences.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  13. #13
    Hyperactive Member CaptainPinko's Avatar
    Join Date
    Jan 2001
    Location
    London, Ontario, Canada
    Posts
    332
    please check the sun java trails before posting, they are quite thorough and will take you from your first java prog to complex db apps with jni and serialization. if you are looking for an ide like vb checkout www.netbeans.org its form builder is pretty similiar. for more simple projects check ouit www.jcreator.com as to jbuilder... IMHO i've passed things of higher quality by my colon
    "There are only two things that are infinite. The universe and human stupidity... and the universe I'm not sure about." - Einstein

    If you are programming in Java use www.NetBeans.org

Posting Permissions

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



Click Here to Expand Forum to Full Width