Results 1 to 3 of 3

Thread: Java newb: Couple of questions need answering :)

Threaded View

  1. #1

    Thread Starter
    Frenzied Member wpearsall's Avatar
    Join Date
    Feb 2002
    Location
    England / UK
    Posts
    1,065

    Java newb: Couple of questions need answering :)

    Hi,

    OK, i am a total newbie to Java Programming.. i downloaded tons of source code, looked thru the code and am starting to take some of the stuff in.

    I have made a chat system in VB, but now, want to create a java applet for people who dont want to download the full application [IE: People who are at school / college / work etc]

    Now,

    As i said, i have downloaded tons of source and started to understand some of the basic stuff...

    The stuff i really need to know to help me get on my way is:

    1) Is there a site which list's all of the Events of a Socket?
    ---- I need to be able to listen for a data arrival on the socket etc
    Code:
    // Like with listening for a click of a command button
    bSend.addActionListener( new SendButton() );
    // it would be nice to know how to listen for data arriving
    wskSocket.add_DataIncoming_Listener( new DataArrival() );
    2) How do i loop through forms [AKA Frames?] to check for the title of the form?
    VB Code:
    1. Dim frm as form, _
    2.       dForm as frmPMForm
    3. for each frm in forms
    4. if frm.caption="Search caption" then
    5.   set dform=frm
    6.   exit for
    7. end if
    8. next frm
    9. if dform is nothing then exit sub
    10. dform.??????(???)

    3) I think i am knowing how to create the forms from a basic class.

    4) I tried to compile my applet to see if my user interface is working, but get the following messages:

    [ EDIT: i fixed this one, i forgot to add a reference / import import java.awt.event.*; ]
    Code:
                                         ^
    C:\Programming\TheWalks\TheWalksChat\Webbased\JavaClient\JavaInterface.java:84: cannot resolve symbol
    symbol  : variable KeyEvent 
    location: class JavaClient.JavaInterface
    		hlpMenu.setMnemonic(KeyEvent.VK_H);
                                        ^
    C:\Programming\TheWalks\TheWalksChat\Webbased\JavaClient\JavaInterface.java:93: cannot resolve symbol
    symbol  : method setJMenuBar (javax.swing.JMenuBar)
    location: class JavaClient.JavaInterface
    		setJMenuBar( menuBar );
                    ^
    can anyone help explain these?...

    Also, a biggy:

    5) How do i make it so i can change a variable from a <param> tag on the webpage applet code?

    IE: String sRoom in the code is set by the param... ?

    Thanks guys.

    Wayne
    Last edited by wpearsall; Feb 6th, 2004 at 05:23 PM.
    Wayne

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