Help with my basic java

Hello i am in a high school programming class and i need help. I have to make an application that draws a basic face, and then i put in different scrollbars, drop menus and checkboxes to control how the face works. I have gotten most of what i need to do but i am stuck on, I need to have a so if i press it they will get closer together of farther apart, which is where im stuck. i can only make them move in the same direction. any ideas???
heres the code.
import java.awt.*;
import java.awt.event.*;
public class Unit9q extends java.applet.Applet implements AdjustmentListener,ItemListener {
     Graphics g;
     Checkbox mybox1,mybox2,mybox3,mybox4,mybox5;
     CheckboxGroup mygroup1,mygroup2;
     Choice mymenubar1,mymenubar2;
     String colorword,shapeword,menuitem1,menuitem2,eyefill,eyesstring;
     Color clr;
     int yaxis,inteyes,ineyes;
     Scrollbar yaxisscroll,eyes;     
     public void init() {
          yaxisscroll=new Scrollbar(0,50,1,120,140);
          yaxisscroll.addAdjustmentListener(this);
          yaxisscroll.setBounds(100,10,100,20);
          add(yaxisscroll);
          yaxis=120;
          eyes=new Scrollbar(0,50,1,120,140);
          eyes.addAdjustmentListener(this);
          eyes.setBounds(100,10,100,20);
          add(eyes);
          inteyes=110;
          mygroup1=new CheckboxGroup();
          mybox1=new Checkbox("Red",mygroup1,false);
          mybox2=new Checkbox("Blue",mygroup1,false);
          mybox3=new Checkbox("Green",mygroup1,false);          
          mybox4=new Checkbox("Filled",mygroup2,false);
          mybox5=new Checkbox("Outlined",mygroup2,false);
          add(mybox4);
          add(mybox5);
          mybox1.addItemListener(this);
          mybox2.addItemListener(this);
          mybox3.addItemListener(this);
          add(mybox1);
          add(mybox2);
          add(mybox3);
          clr=Color.white;
          mymenubar1=new Choice();
          mymenubar1.addItem("Square");
          mymenubar1.addItem("Circle");
          mymenubar1.addItem("Rectangle");
          mymenubar1.addItem("Oval");
          mymenubar1.addItemListener(this);
          mymenubar2=new Choice();
          mymenubar2.addItem("Square");
          mymenubar2.addItem("Oval");
          mymenubar2.addItemListener(this);
          add(mymenubar1);
     public void adjustmentValueChanged(AdjustmentEvent event){
          yaxis=yaxisscroll.getValue();
          inteyes=eyes.getValue();
          repaint();
     public void itemStateChanged(ItemEvent event) {
          menuitem1=mymenubar1.getSelectedItem();
          menuitem2=mymenubar2.getSelectedItem();
          if (mybox1.getState()==true) {clr=Color.red;}
          else if (mybox2.getState()==true) {clr=Color.blue;}
          else if (mybox3.getState()==true) {clr=Color.green;}
          repaint();
     public void paint(Graphics g) {
          g.setColor(Color.black);
          if (menuitem1.equals("Rectangle")){
               g.drawRect(100,100,70,90);}
          else if (menuitem1.equals("Oval")){
               g.drawOval(100,100,75,90);}
          else if (menuitem1.equals("Circle")){
               g.drawOval(100,100,80,80);}
          else if (menuitem1.equals("Square")){
               g.drawRect(100,100,80,80);}     
          if (menuitem2.equals("Circle")){
               g.drawOval(80,100,10,10);}
          else if (menuitem2.equals("Square")){
               g.drawRect(80,100,10,10);}     
                    g.setColor(clr);
          if (mybox4.getState()==true) {
               g.fillRect(inteyes,120,10,10);
               g.fillRect(ineyes,120,10,10);}
          else if (mybox5.getState()==true) {
               g.drawOval(inteyes,120,10,10);
               g.drawOval(ineyes,120,10,10);}     
          ineyes=inteyes+42;
          g.setColor(Color.black);     
          g.fillOval(128,yaxis,15,22);
          g.drawArc(111,160,50,20,0,180);     
     } //thank you if you can solve it

Next time you post code, use the CODE button or [code] and [/code] tags so that it maintains the formatting from your editor.
If two things are moving int the same direction, your adding N to both of their x-coordinates. If you want one to move in one direction and the other in the other direction, then you have to add N to one and -N to the other.

Similar Messages

  • Need help with a basic java thing..

    Sorry, just started java a few weeks ago and i'm having trouble figuring out how to do something.
    I wanted to know how to make this work. It cant be more than 6 characters in length and of those six characters, the first two have to be letters only, followed by a dash (-) and then three numbers. EG: ab-234 or gf-643...
    Im using it as a serial number generator type thing, thats only one part of the entire program, but I cant figure it out.
    Just need the most basic way to do that if anyone could help! been looking for hours in a couple java books i have and dont know where to look or what to look for!!
    Any help figuring out the code for that would be great! Here's what I have so far and how i need the rest to be implemented! Thanks! PS: using TextIO
    <code>
    String itemNum1
         itemNum1 = new String ( " Enter Item Number(AB-123): " );
         TextIO.put("\n" + itemNum1);
         itemnum = TextIO.getlnString();
    </code>

    Oh hey sorry, i figured the bit of text i put in there
    would be enough. I basically need a user to enter the
    information, but i just need to know (or get a hint)
    of how to prevent them from entering an invalid
    number/serial code type thing in regards to the
    parameters that I need met. (such as no more than 6
    chars, but alternating numbers/letters). I presume I
    use the char and not the getlnString command but
    nonetheless im still stuck as to how I'd manage that.
    Do i need to code each character seperately? (such as
    letters by themselves, then another prompt to enter
    the numbers??) or is there a way to get it all in one
    go?
    Thanks for any advice! oh and Sorry for the bad
    wording in my question :P.
    You could read the String from console using something like
    public static String readWord()
       {  int ch;
          String r = "";
          boolean done = false;
          while (!done)
          {  try
             {  ch = System.in.read();
                if (ch < 0
                   || java.lang.Character.isSpace((char)ch))
                   done = true;
                else
                   r = r + (char) ch;
             catch(java.io.IOException e)
             {  done = true;
          return r;
       }you would have to modify it according to your needs and after that you could use the String API to confirm if the user has entered it right or not. If not you could ask him to do that again

  • Knight tour programming with only basic java

    i had this assignment from school which ask us to create a program to calculate how many posssibilities to complete knight's tour from a position using basic java and not using applet. So far i can only create an incomplete program which can only go a speccific way and is also incomplete. i am trying to understand the jaava applet type of knight tour program but got too confused as i have just started learning this. Please help me with this.
    here's my code:
    public class uk16638_a3{
         public static void main(String[] args){
         int horizontal[] = {2,1,-1,-2,-2,-1,1,2};
         int vertical[] = {-1,-2,-2,-1,1,2,2,1};
         int chessBoard[][]=new int[8][8];
         int move, currentRow = 0, currentCol= 0, move_count = 0, new_vert, new_horz;
    for(int i=0; i<8; i++)
         for(int j =0; j<8; j++)
              chessBoard[i][j] = 0;
    chessBoard[0][0] = 1;
    do{
    for(move=0;move<8;move++){
    new_vert = currentRow + vertical[move];
    new_horz = currentCol + horizontal[move];
    if ( (new_vert>=0) && (new_vert < 8) )
    if( (new_horz>=0) && (new_horz < 8) )
    if( chessBoard[new_horz][new_vert]==0 ) {
    chessBoard[new_horz][new_vert] = 1;
    move_count++;
    currentRow = new_vert;
    currentCol = new_horz;
    }}}while(move<8);}}

    Sorry with the inconvenience cause i am new with this forum so i am causing many problems to all of you. here's the full code i put but i would really like to ask someone to teach me on creating a backtrack and let the knight moves following a different sequence from the one i already set.
    public class uk16638_a3{
    public static void main(String[] args){
    //the movements of a knight horizontally and vertically
    int horizontal[] = {2,1,-1,-2,-2,-1,1,2};
    int vertical[] = {-1,-2,-2,-1,1,2,2,1};
    int chessBoard[][]=new int[8][8];
    int move, currentRow = 0, currentCol= 0, move_count = 0, new_vert, new_horz;
    //setting all elements in the array to 0
    for(int i=0; i<8; i++)
    for(int j =0; j<8; j++)
    chessBoard[i][j] = 0;
    //the knight starts here
    chessBoard[0][0] = 1;
    //using do while loop, i try to move the knight following the sequence i had already set in the array above. But because its moving at the same direction all the time, it gets stuck.
    do{
    for(move=0;move<8;move++){
    //setting the new coordinates for it to move to
    new_vert = currentRow + vertical[move];
    new_horz = currentCol + horizontal[move];
    if ( (new_vert>=0) && (new_vert < 8) )
    if( (new_horz>=0) && (new_horz < 8) )
    //new position check if its already occupied or not, if occupied it will move on to the next part of the move sequence i set
    if( chessBoard[new_horz][new_vert]==0 ) {
    chessBoard[new_horz][new_vert] = 1;
    move_count++;
    //current coordinate of the new knight position
    currentRow = new_vert;
    currentCol = new_horz;
    }}}while(move<8);}}
    Edited by: Mikki88 on Mar 2, 2009 1:53 AM

  • Looking for Help with Hyperion to JAVA

    I am looking for help with connecting Hyperion to Java. We are in Maryland but would be willing to work out something for remote consulting. If you have experience with connecting web services, hyperion, and Java and would be interested in about 80 hours of consulting please contact me at:[email protected] x4846

    Hi,
    From your description, you want to achieve the following goal:
    Configure Exchange to filter the attachments if the size is over 10 MB and store it in a public folder, and then forward the email to Salesforce.
    Based on my knowledge, I'm afraid that it can't be achieved. Exchange can filter messages with attachments, but it couldn't store these attachments on public folder automatically. Also, I don't see any transport rule can do it.
    Hope my clarification is helpful.
    Best regards,
    Amy Wang
    TechNet Community Support

  • Need a help with something basic, renaming pages made in muse

    Hi All
    can someone help me with a basic task,
    I need to rename a page ivve made in muse containing slide shows or forms,
    when I upload via FTP it over writes the websites index.html page
    any suggestions on what i do to rename Ive tried everything
    Thank you, In anticipation
    Julie

    Hi Julie,
    To rename a page name in Muse, please right click on page and go to page properties. You can rename the page name of all the pages as well as the "file name" in Muse but you can't change the 'File name" of the index page in Muse. Please refer to the following screenshot :
    If you choose to export the site as HTML, you can then change this as well but then the menu items links will be broken and you will have to manually link all the menu items outside muse.
    Hope this helps.
    Cheers!
    Aish

  • I need help with a basic rock paper scissors program!

    i need to make a program that allows the computer to play rock paper scissors at random and compare the results with user and tell who wins or if its a tie. can anyone help me?

    import java.util.Scanner;
    import java.util.Random;
    public class RockPaperScissors
    public static final int ROCK = 1;
    public static final int PAPER = 2;
    public static final int SCISSORS = 3;
    public static void main(String[] args)
    final int NUM_CHOICES = 3;
    Random generator = new Random();
    int userWins = 0;
    int compWins = 0;
    int ties = 0;
    int compChoice, userChoice;
    boolean exit = false;
    Random randGen = new Random();
    Scanner scan = new Scanner(System.in);
    System.out.println("Enter your choice: ");
    userChoice = scan.nextInt();
    System.out.println("Computers Choice: ");
    compChoice = scan.nextInt();

  • Help with a SIMPLE java thing

    I've only got ONE handful of hair left.
    I'm trying to build a series of dropdown boxes; a day dropdown (Mon, Tue, Wed...), a month dropdown (Jan, Feb, Mar...), a year dropdown, hour dropdown, minute dropdown, and an am/pm dropdown.
    I think I want to build my dropdowns using "for" loops something like this:
    for (i=0;i<12;i++) {
    myStringBuffer.append("<option>" + [someUnknownFunctionThatReturnsTheFirstThreeLettersOfTheMonth(i)] + "</option>")
    I've been trying to mix up various combinations of Date objects (most date functions seem to be depreciated), Calendar Objects, DateFormat Objects and SimpleDateFormat Objects but nothing seems to want to perform the function that I need.
    I've had iffy success creating a calendar object, setting the Month to "i", using the getTime function to return a Date object which I can then pass to the SimpleDateFormat object using the .format(Date) function, after setting the pattern to "EEE", but it seems like just an incredibly complicated way to do what ought to be a simple function...i.e. convert a number 0-11 (or 1-12, I'm not picky) into the name of a stinking Month! Arrgh.
    If anyone can help, I thank you.

    I've done that before, so i'll share it with you.
    import java.text.SimpleDateFormat;
    import java.text.DateFormatSymbols;
    import java.util.Calendar;
    import java.util.Date;
    public String createListOfMonth(String pName) {
    StringBuffer sbMonth = new StringBuffer();
    DateFormatSymbols fm = new DateFormatSymbols();
    String[] arrMonth = fm.getMonths();
    sbMonth.append("<select name=\"" + pName + "\">");
    sbMonth.append("     <option value=\"\">Month</option>\n");
    for (int i=0; i<arrMonth.length; i++) {
    if (!arrMonth.trim().equals("")) {
    String sValue = "0000" + (i + 1);
    sValue = sValue.substring(sValue.length() - 2);               
    sbMonth.append("     <option value=\"" + sValue + "\">" + arrMonth[i] + "</option>\n");
    sbMonth.append("</select>");
    return (sbMonth.toString());
    You can manipulate the symbol (either for months, days) using different locale. You can see the API for java.text.DateFormatSymbols in Java2 SE.
    Regards,
    Hariyanto

  • Im DROWNING! need help with a simple java assignment! plz someone help me!

    i need help with my java assignment, with validating a sin number. easy for must who know java. im drowning... please help!

    You will need to store each digit of the social insurance number in a field of its own. To validate the entry you will:
    1. Multiply the 2nd, 4th, 6th and 8th digit by 2.
    2. If the product of any of the four multiplications result in a value greater than 9, add the two resulting digits together to yield a single-digit response. For example 6 * 2 = 12, so you would add the 1 and the 2 to get a result of 3.
    3. Add these four calculated values together, along with the 1st, 3rd, 5th, and 7th digits of the original number.
    4. Subtract this sum from the next highest multiple of 10.
    5. The difference should be equal to the 9th digit, which is considered the check digit.
    Example of validating S.I.N. 765932546
    1st digit 7
    2nd digit (6*2 =12 1+2=) 3
    3rd digit 5
    4th digit (9*2 = 18 1+8 =) 9
    5th digit 3
    6th digit (2*2 = 4) 4
    7th digit 5
    8th digit (4*2 = 8) 8
    Total 44 next multiple of 10 is 50
    50-44 = 6 which is the 9th digit
    Therefore the S.I.N. 765932546 is Valid
    ********* SIN Validation *********
    Welcome - Please enter the first number: 120406780
    Second digit value multiplied by 2 4
    Fourth digit value multiplied by 2 8
    Sixth digit value multiplied by 2 12
    Eighth digit value multiplied by 2 16
    Value derived from 6th digit 3
    Value derived from 8th digit 7
    The total is 30
    Calculated digit is 10
    Check digit must be zero because calculated value is 10
    The SIN 120406780 is Valid
    this is my assignemtn this is what i have! i dont know where to start! please help me!
    /*     File:     sinnumber.java
         Author:     Ashley
         Date:     October 2006
         Purpose: Lab1
    import java.util.Scanner;
    public class Lab1
              public static void main(String[] args)
                   Scanner input = new Scanner(System.in);
                   int sin = 0;
                   int number0, number1, number2, number3, number4, number5, number6, number7, number8;
                   int count = 0;
                   int second, fourth, sixth, eighth;
                   System.out.print("\t\n**********************************");
                   System.out.print("\t\n**********SIN Validation**********");
                   System.out.print("\t\n**********************************");
                   System.out.println("\t\nPlease enter the First sin number: ");
                   sin = input.nextInt();
                   count = int.length(sin);     
                   if (count > 8 || count < 8)
                   System.out.print("Valid: ");
         }

  • Need help with long term Java problems

    I've been having problems with Java on my computer for about a year now, and I'm hoping that someone here can help me out.
    Java used to work fine on the computer when I first got it (a Dell laptop) and I hadn't installed anything myself. But then one day it stopped loading Java applets, and hasn't worked since. By this, I mean that I get the little colorful symbol in a box when I try to play Yahoo games, use the http://www.jigzone.com site, go to chat rooms, etc. Java menus on websites like http://www.hartattack.tv used to work still, but lately they've been giving me that symbol too.
    I've tried downloading a newer version of Java, but nothing I do seems to work, and I don't know of anything I did to trigger it not working. I'm hoping there's a simple solution to this, and I'm just dumb.
    Thanks.

    This might be way off, but it's something that's tripped me up in the past:
    If you are using Sun's Java plugin, the first time you go to a site that has a particular Java applet, you may be asked to approve/reject a security request.
    If you have clicked on any other windows while the request is first being loaded (which can take some time, because this is swing based), then the security dialog box does not pop to the top of the window stack, and doesn't add an entry into the task bar.
    It appears that Java just doesn't work, but it's actually waiting for you to click "Yes". You can check this by hitting alt-tab and seeing if the Java coffee cup icon is one of the options.
    - K

  • Need help with Visual BASIC

    I am in an intro to programming course, and I am writing a console on Visual Basic 2013.  My problem with Visual Basic right now is that I cannot get the formula to work.  All of my inputted values end up being 0's.  Am I using incorrect parameters,
    am I misunderstanding how to use arguments; am I not coding correctly?  The scenario for my problem is:
          Areas of Rectangles: The area of a rectangle is the rectangle’s length times its width.  Design a program that asks for the length and width of two rectangles. The program should tell the user which rectangle has the
    greater area, or if the areas are the same.
    //My code is 
    Module Module1
        Sub Main()
            Dim LENGTH As Double = 0
            Dim WIDTH As double = 0
            Dim AREA_1 As Double
            Dim AREA_2 As Double
            Dim RECTANGLE As String = " "
            area1(LENGTH, WIDTH)
            areaCalc1(AREA_1, LENGTH, WIDTH)
            area2(LENGTH, WIDTH)
            areaCalc2(AREA_2, LENGTH, WIDTH)
            decision(AREA_1, AREA_2, RECTANGLE)
            displayDec(RECTANGLE)
            Console.WriteLine("Press any key to exit...")
            Console.Read()
        End Sub
        Sub area1(ByVal LENGTH, WIDTH)
            Console.WriteLine("Please input the following for your first rectangle:")
            Console.Write("Length: ")
            LENGTH = Console.ReadLine()
            Console.Write("Width: ")
            WIDTH = Console.ReadLine()
        End Sub
        Sub areaCalc1(ByVal AREA_1, ByRef LENGTH, WIDTH)
            AREA_1 = LENGTH * WIDTH
            Console.WriteLine("This is the area for rectangle 1: " & AREA_1)
        End Sub
        Sub area2(ByVal LENGTH, WIDTH)
            Console.WriteLine("Please input the following for your second rectangle: ")
            Console.Write("Length: ")
            LENGTH = Console.ReadLine()
            Console.Write("Width: ")
            WIDTH = Console.ReadLine()
        End Sub
        Sub areaCalc2(ByVal AREA_2, ByRef LENGTH, WIDTH)
            AREA_2 = LENGTH * WIDTH
            Console.WriteLine("This is the area for rectangle 2: " & AREA_2)
        End Sub
        Sub decision(ByRef AREA_1, AREA_2, ByVal RECTANGLE)
            If AREA_1 < AREA_2 Then
                RECTANGLE = "rectangle 2"
            Else
                RECTANGLE = "rectangle 1"
            End If
        End Sub
        Sub displayDec(ByRef RECTANGLE)
            Console.WriteLine("The rectangle with the greater Area is " & RECTANGLE)
        End Sub
    End Module

    Hi,
      If you are just beginning to program i highly recommend setting the following options in the Visual Studio menu (Tools/Options). Open the Options window and go to the (Projects and Solutions) and click on (VB Defaults). Now set the options as follows.
    Option Strict - On
    Option Explicit - On
    Option Infer - Off
     And probably one of the most important things to do is learning to Debug your code. That will save you hours of headaches when you get unexpected results in your applications. You will know how to track it down and find where in the code your results
    are being thrown off. There are quite a few Debugging tutorials on the internet. Here are a few decent ones.
    Debugging Express
    Breakpoints and Debugging Tools
    If you say it can`t be done then i`ll try it

  • Need help with running a Java program on Linux

    I am trying to get a Java program to run on a Linux machine. The program is actually meant for a Mac computer. I want to see if someone with Java experience can help me determine what is causing the program to stall. I was successful in getting it installed on my Linux machine and to partially run.
    The program is an interface to a database. I get the login screen to appear, but then once I enter my information and hit enter the rest of the program never shows, however, it does appear to connect in the background.
    Here is the error when I launch the .jar file from the command screen:
    Exception in thread "main" java.lang.IllegalArgumentException: illegal component position
    at java.awt.Container.addImpl(Unknown Source)
    at java.awt.Container.add(Unknown Source)
    I am not a programmer and I am hoping this will make some sense to someone. Any help in resolving this is greatly appreciated!

    Well, without knowing a little bit about programming, and how to run your debugger, I don't think you're going to fix it. The IllegalArgumentException is saying that some call does not like what it's getting. So you'll have to go in an refactor at least that part of the code.

  • Help with 'AI' in Java

    Hello,
    I am very new to Java and am stuck on 1 final part of a piece of work I am completing. I have written a MIDlet game (similiar to noughts and crosses) where each player takes it in turn to click a button until one of the players has reached the win state. I now however need to adapt this so that it is 1 human player against 1 computer player. I don't need to provided the computer player with any decision making logic (as of yet), but would just like it to randomly select a button each time it is it's turn.
    for buttons, I am using item commands placed on top of StringItems and given them the BUTTON appearence in their properties.
    I have already declared a random variable which generates a random number between 1-10 (inclusive), but am unsure how to tell the computer to (for example) select button 5 if a 5 is generated.
    As I said I have this working for 2 human players, and am happy to provide source code of this (although it will probably loook very poor)
    Any help or hints would be greatly appreciated.
    Regards,
    nosaj_ccfc

    Project Moon,
    I do not have the StringItems declared in either a list or an array, I have actions assigned to them depending on whether they have been selected by either player. I have provided an example of one below
    if (item == Word1) {                     
                if (command == itemCommand1) {                   
                    // Insert pre-action code here
                    // Do nothing                        
                    if(PlayerTurn == 1)
                        WordTableLayout.setValue(0,Player1Row,Word1.getText());
                        CurrentPlayer.setLabel("Player 2");
                        PlayerTurn = 2;
                        Player1Row++;
                        P1WinComboA++;
                        P1WinComboB++;
                    else if(PlayerTurn == 2)
                        WordTableLayout.setValue(1,Player2Row,Word1.getText());
                        CurrentPlayer.setLabel("Player 1");
                        PlayerTurn = 1;
                        Player2Row++;
                        P2WinComboA++;
                        P2WinComboB++;
                    Word1.removeCommand(itemCommand1);
                }                       

  • Need help with mac and java

    Hi, I'm trying to develop an application on a Machintosh OSX 10.2.8 machine.
    I'm having a herrendous time trying to get quicktime to work on it.
    I've somehow managed t oget 1.3.1 and QTJava.jar to work together but now i need encryption, however that requires 1.4+
    Now 1.4.1 doesnt work with quicktime
    I've downloaded the latest software upgrades but Ive got no idea how to set up quicktime to work with java 1.4.1
    Now to add on top of that mac reports it can use AES encryption. this is from source code ripped striaght from this website.
    But first and foremost can anyone, annyonee help me out with setting up 1.4.1 with quicktime?
    Thank you

    If you need encryption with Java 1.3.1, download the JCE from either Sun (http://java.sun.com/products/jce/) or Bouncy Castle (http://www.bouncycastle.org/).
    Cheers,
    --Arnout                                                                                                                                                                                                                                                                                                                                                                   

  • Help with HTML and JAVA

    Hi.
    I'll have this question, and can't find the right answer...
    Suppose is this site called xyz.com and you need to register to be a member
    For simplicity member log-in page is simple...contains only login and password fields(Submit too) in HTML code:
    <html>
    <body>
    <form name="input" action="html_form_action.asp" method="get">
    User ID: <input type="text" name="ID" /><br />
    Password: <input type="password" name="pwd" /><br />
    <input type="submit" value="Submit" />
    </form>
    </body>
    </html>Will I be able to build a Java application witch will:
    1-Send me to this web-page
    2-Place my chosen id and password in the right place
    3-"Press" Submit button.
    So I open this Java Swing application , and Go button will send me to the members page of my xyz.com page.
    Thank you for the help.

    altisw5 wrote:
    Go button will send me to the members page of my xyz.com page.It depends on what you mean by "send me".
    If you mean access data on the members page through your program, yes.
    If you mean open a browser window to that page, I guess doable but might be tricky (with Robot and stuff).
    If you mean physically send you on the internet, no.

  • I need some help with sound in Java

    hi, i`m new to java. i`m having a through problems with a program i`m writing. i`ve added a song to an applet but it does not play. The code for this is:
    private AudioClip music;
    music = getAudioClip(
    getDocumentBase(), "titantic.wav" );
    Can some 1 tell me is that the write code. please help.

    2 things.
    1. You must also send a command to play the music file.
    2. I'm not certain, but I think that you can only load .au files this way.

Maybe you are looking for

  • Reconciliation Via DIAPI

    Hi, My client needs me to create two documents via the SDK using DIAPI (SAPbobsCOM).  I am creating an A/P Invoice and an A/P Credit Memo.  He wants me to reconcile the two after they are created but I can't seem to see the object that will allow me

  • How to change the column width in Smartforms..?

    Hi All.. I need to change the column width in a smartform. The requirement has been mentioned as follows... Adjust the column width of the following columns: MATERIAL: 14 char DESCRIPTION: 20 char How to perform this..?? Where can i find the column w

  • IPhoto book - Never shipped

    How frustrating. I ordered my first printed book from Apple and it supposedly shipped on July 13 to be delivered on July 17. I paid for express shipping. On July 17, I checked the tracking number and the only information was that the order was electr

  • Restricting project profile in CJ20N/CJ01 t-code

    Hi Experts, Based on the client requirement we have created a new Project Profile named as theShutdown Project. The type of Project is ShutDown. The client wants to restrict the same only for the Plant users usage.  I know that the type of the projec

  • J2EE - Reports using Business Objects.

    Hi Friends, We have a requirement to generate reports in our project using Business Objects v5.1.8. Some users/Actors will have assess the reports through Webi of business objects and other requirement is to do some selection criteria in web page and