Help with commandLink, actionListener, param in a simple CRUD example

Hi All,
I'm trying to build a very simple CRUD (create read update delete) interface as a proof of concept (concept being that I have some aptitude with JSF) and here is my problem:
I have a dataTable, each row of which represents a campaign object. I want an "edit" link in each row that will load a single-edit page for the campaign in that row. I am not sure how to access the value of the param (campaignId) within the backing bean's actionListener method. Below is the code for the link and thanks in advance.
Matt
<h:commandLink
   actionListener="#{CampaignBean.chooseCampaign}"
   action="#{CampaignBean.editCampaign}"
   rendered="#{not campaign.editable }">
               <h:outputText value='#{campaign.campaignName}'
                             rendered="#{not campaign.editable }"/>
               <f:param name="chosenCampaign"
                             value="#{campaign.campaignId }"/>
          </h:commandLink>

Thank you very much! Actually a co-worker had pointed me to your site yesterday afternoon and I was going to post a link to it. Your articles are very helpful!!!

Similar Messages

  • Need Help with CommandLink Passing rowKeyStr to 2nd JSPX Page

    I've been working about 8 hours on something that should be simple - I have a databable displaying rows of data with a simple command link on one of the columns that will send the user to a 2nd page with a single record form showing detailed information for the selected row.
    The problems I'm having:
    * When I press the commandlink I do not get the correct record on the 2nd page
    * Also I'm receiving the following error: JBO-25020: View row of key oracle.jbo.Key[11 ] not found in SearchViewIterator
    When I use the af:tableselectone (selection) button to select the row first and then click the commandlink, the 2nd page DOES display the correct row, however I still receive the 25020 error above.
    Note I am using the same View Object and Iterator for both pages.
    I have compared my code against the SRDemo application and cannot see any differences - I was hoping someone could review my steps to see if I'm missing something (using JSF and ADF BC 10.1.3):
    Page 1 JSPX Code Snippet (commandLink / ActionListener):
    <af:commandLink actionListener="#{bindings.setCurrentRowWithKey.execute}"
    action="viewisp"
    text="setCurrentRowWithKey"
    disabled="#{!bindings.setCurrentRowWithKey.enabled}">
    <af:setActionListener from="#{row.rowKeyStr}"
    to="#{processScope.rowKeyStr}"/>
    </af:commandLink>
    Page 1 JSPX Page Definition File Snippet:
    <action id="setCurrentRowWithKey" IterBinding="SearchViewIterator"
    InstanceName="SearchDataControl.SearchView"
    DataControl="SearchDataControl" RequiresUpdateModel="false"
    Action="96">
    <NamedData NDName="rowKey" NDValue="#{row.rowKeyStr}"
    NDType="java.lang.String"/>
    </action>
    JSPX Page 2 (destination - single form) - Page Definition Snippet:
    <executables>
    <iterator id="SearchViewIterator" RangeSize="10" Binds="SearchView"
    DataControl="SearchDataControl"/>
    <invokeAction id="setCurrentRowWithKeyStr" Binds="setCurrentRowWithKey"
    RefreshCondition="#{adfFacesContext.postback==false}"/>
    </executables>
    <action id="setCurrentRowWithKey" IterBinding="SearchViewIterator"
    InstanceName="SearchDataControl.SearchView"
    DataControl="SearchDataControl" RequiresUpdateModel="false"
    Action="96">
    <NamedData NDName="rowKey" NDValue="#{processScope.rowKeyStr}"
    NDType="java.lang.String"/>
    </action>
    Finally - I did see some other posts related to the JBO-25020 error. The recommended Solution was to add the following code to the underlying ViewObjectImpl class:
    protected void create()
    {    setManageRowsByKey(true);
    super.create(); }
    This had no affect.
    thanks for any help.....
    ps what exactly is stored in the row.rowKeyStr? is it based on data columns in the row?

    Finally got this to work - thought I would post the solution that worked for me here in case anyone else runs into this:
    Note: Page#1 = Search Form - ADF parameter form and ADF read-only table (uses CommandLink to pass record to page#2)
    Page#2 = ADF read-only form - uses same VO and same iterator as page 1
    1. As Frank in his reply above, I don't need to use an ActionListener, but only use the commandlink for navigation. I did need also to set the current row when the user clicks the command link as described in the JDev help (Adding Tables | Setting the Current Object Using a Command Component) - this was a step I was missing before.
    2. NOW, here is where it gets Interesting - to avoid the issues of:
    a. page#2 not displaying the correct record selected, or, inconsistently displaying the correct record; and/or,
    b. receiving a "JBO-25020: View row of key oracle.jbo.Key[num] not found in xxIterator"
    I had to EITHER:
    A. Set the SyncMode for the DataControl in databindings.cpx = Batch (as described in      http://www.oracle.com/technology/products/jdev/tips/muench/batchmode/index.html)
    OR,
    B. Keep the SyncMode for the DataControl as Immediate, BUT override the following method in ViewObjImpl as described in some previous forum threads related to JBO-25020 error:
    protected void create()
    {     setManageRowsByKey(true);
    super.create(); }
    This is what I found (after much trial & error) worked for me - I'm curious to see if others have come to the same conclusions.
    thanks
    Tom

  • Help with driving f:param  in  a command***

    I have the following problem that I can't resolve:
    Having a inputtext and a commandlink, I need to pass the inputtext value as a commandlink param in a request scope, to make some logical action in the back bean, I have been trying using binding and f:inputhidden, but I can't find the way. I find some info in:
    http://balusc.blogspot.com/2006/06/communication-in-jsf.html
    If someone have some code example please help!!!

    If placed in the same form, the h:inputText value is just accessible in the action method?

  • Help with Button actionlistener

    Hi friends , I have simple question but i am not getting any idea how to solve this..
    I want to call a method in one class from other class...ie
    I have a class called checklistmod which contains method called onClickDeleteButton(CheckInfoItem checkInfoItem) where Checkinfoitem is another help class in the same checklistmod class.
    I have another class called showlist which contains a button called "Delete".
    my question is i want to add a actionlistenet for "Delete" button such that when i click the "Delete" button it should call the method onclickDeleteButton(CheckInfoItem checkinfoitem) method in checklistmod class..
    Does anyone has an idea
    sorry if my question in not clear..
    Thanks in advance

    So call it. These are just classes and methods. They should be treated like any other classes and methods. Of course since (I assume) onClikcDeleteButton is an instance method (not static) the class showlist will have to have access to (a reference to) an instance of the class checklistmod.
    Also, the class CheckInfoItem has to be public so that showlist can create an instance of it to pass to the method.
    One general technique would be for checklistmod to register itself to be called when the delete is pressed.

  • I am trying to load new Cd's onto my iTunes in my Mac. But it comes up with cannot convert file? Please can someone help with something that should be so simple.

    I am trying to upload new CD's onto my iTunes account on my Mac but it coming up with cannot convert file.
    "You don't have access for your iTunes media folder or a folder within it. What do I need to do?

    Read the part about changing permissions on the iTunes folder in: https://discussions.apple.com/message/11583914

  • Need help with basic user events in Queued state machine example

    I have written a little queued state machine example to try to teach myself about creating and using user events.  The objective of the machine is to periodically choose a number (I'm doing it now with a control instead of a random number generator for troubleshooting), and compare that number with the number I have set in a control.  When they match, I want to cause an event to fire so I can do something about having found a match.  The examples in the LV Help file references show the events within the event structure, but I want to reach out of a state and cause an event ....
    Can someone point me in the right direction here?
    Thanks
    Hummer1
    Solved!
    Go to Solution.
    Attachments:
    User Event Generator Example01 snip.png ‏102 KB

    Yep....That was it...I had tried to do that but got fouled up with the variant definition...so defined the user event using a boolian and did the same in the case structure where I wanted to create the event and it worked great...
    Thanks.
    Here is the final version...not bulletproof, but does have a queued state machine using a user event to cause an event to fire.
    Hope you find it useful.
    Hummer1
    Attachments:
    User Event Generator Example01.vi ‏45 KB
    Operating States Enum Example01.ctl ‏5 KB

  • Help with pathfinding program

    hi,
    i study java at school and i need help with my project.
    im doing a simple demonstration of a pathfinding program whose algoritm i read off Wikipedia (http://en.wikipedia.org/wiki/Pathfinding)where the co-ordinates of the start and end points
    are entered and the route is calculated as a list of co-ordinates. Here is the section of code i am having trouble with-
    void find_path(int x,int y,int p,int q)
    int t1;int t2;
    int temp_pool[][]=new int[4][3];//stores contagious cells of elements in grid pool
    int grid_pool[][]= new int[100000][3];
    int pass_pool[][]=new int[4][3];//stores the pool of squares which can be added to the list of direction
    int path[][]= new int[10000][3];//stores actual path
    int count=1;int note=10;int kk=0;
    int curx,cury;
    //the above arrays contain 3 columns - to store x and y co-ordinate and a counter variable(the purpose of which will become clear later)
    grid_pool[0][0]=p;
    grid_pool[0][1]=q;
    grid_pool[0][2]=0;
    int counter=grid_pool[0][2];
    for(int i=0;i<=100;i++)
    counter++;
    curx=grid_pool[0];
    cury=grid_pool[i][1];
    temp_pool[0][0]=curx-1;
    temp_pool[0][1]=cury;
    temp_pool[0][2]=counter;
    temp_pool[0][0]=curx;
    temp_pool[0][1]=cury-1;
    temp_pool[0][2]=counter;
    temp_pool[0][0]=curx+1;
    temp_pool[0][1]=cury;
    temp_pool[0][2]=counter;
    temp_pool[0][0]=curx;
    temp_pool[0][1]=cury+1;
    temp_pool[0][2]=counter;
    int pass=0;
    for(int j=0;j<=3;j++)
    int check=0;
    int in=temp_pool[j][0];
    int to=temp_pool[j][1];
    if(activemap[in][to]=='X')
    {check++;}
    if(linear_search(grid_pool,in,to)==false)
    {check++;}
    if(check==2)
    pass_pool[pass][0]=in;
    pass_pool[pass][1]=to;
    pass++;
    }//finding which co-ordinates are not walls and which are not already present
    for(int k=0;k<=pass_pool.length-1;k++)
    grid_pool[count][0]=pass_pool[k][0];
    grid_pool[count][1]=pass_pool[k][1];
    count++;
    if(linear_search(grid_pool,x,y)==true)
    break;
    //in this part we have isolated the squares which run in the approximate direction of the goal
    //in the next part we will isolate the exact co-ordinates in another array called path
    int yalt=linear_searchwindex(grid_pool,p,q);
    t1=grid_pool[yalt][2];
    int g1;int g2;int g3;
    for(int u=yalt;u>=0;u--)
    g3=find_next(grid_pool,p,q);
    g2=g3/10;
    g1=g3%10;
    path[0]=g2;
    path[u][1]=g3;
    path[u][2]=u;
    for(int v=0;v<=yalt;v++)
    System.out.println(path[v][0]+','+path[v][1]);
    ill be grateful if anyone can fix it. im done with the rest though

    death_star12 wrote:
    hi,
    i study java at school and i need help with my project.
    im doing a simple demonstration of a pathfinding program whose algoritm i read off Wikipedia (http://en.wikipedia.org/wiki/Pathfinding)where the co-ordinates of the start and end points
    are entered and the route is calculated as a list of co-ordinates. Here is the section of code i am having trouble with-
    ...The part "i am having trouble with" means absolutely nothing to the people who are answering questions here. It's like going to the doctor with a broken rib and just saying "doc, I don't feel so well". Get my point?
    Also, please take the trouble to properly spell words and use a bit of capitalization. Your question is hard to read as it is, which will most probably cause (some) people not to help you. And lastly, please use code tags when posting code: it makes it so much easier to read (see: [Formatting Messages|http://mediacast.sun.com/users/humanlever/media/forums_text_editor.mp4]).
    Thanks.

  • Hi, I need help with scrolling

    Hello I am Kevin Jin, I am working a huge project acually not that big, but I need help with five things, i mihgt have more things in my mind but here it is
    1. I need help with scrolling like where you have buttons for example or press on a navigation bar tab, then it goes to that specific pace of the page, for a one page website, for example some sites you press on contacts and gose down to the bottom of the page where the contacts place is located, not opening a new link.
    2.Second also I need help with navigation bar, where it fallows the scroll as it gose down, like for example when it is html the object is fixed to the top, and when you scroll down it will fallow it it,
    3.I need Parallex scrolling where you can have the timeline or animations run while you scroll in the meantime and have animation running all the time, for example the infographic site where the bees are fluying but still have seperate animations while you scroll
    4.I am so sorry i have two more to go, i appreciate your help, I would also like to ask if like looping each animations sperately, not looping the whole timeline, can it be possible to loop an animation while you have all the interactivity witht he site like looping seperately all the time, without interfeering with all the other animation
    5.I also are wondering if you can create multiple pages on one animate project, like multiple pages with html
    I just moved on to edge animate from html, and html was also beirf learn for me and mostly i was doing design work, and i thought getting out of graphic river and moving on the theme forest would be a better idea for me, thank you guys so much of the help and add me on skype : kevin2019170 or add me on facebook ; [email protected] or graphicriver, www.graphicriver.net/user/phantomore I would appriciate if you just would like contact me through SNS since I have that in hany 24 hours long, but the thred will also do, thank you doo much foryour help,
    P.S, I want also all the five things to work on one aimate project not interfeering with other ideas liek all five questions i had should run on one site,
    THANK YOU SO MUCH FOR YOUR HELP AND I APPRICIATE YOUR HELP!

    1.
    write this code in your button Click
    $('html,body').animate({scrollTop: sym.$("Your Symbole Name Here").offset().top}, "slow"); // scroll to the top of that symbol name
    Or :
    $('html,body').animate({"scrollTop":"600px"}, 750); // Higher value means slower , scroll to top page
    1 and 2 see this post http://forums.adobe.com/message/5531344#5531344
    3 use edge commons plugin http://www.edgedocks.com/edgecommons
    4.just put the animations behind eachother so when 1 is done, start with the animating the other symbol/div
    5. i thin its best just to make for every page a new project or make the site in muse.

  • Need help with a simple program (should be simple anyway)

    I'm (starting to begin) writing a nice simple program that should be easy however I'm stuck on how to make the "New" button in the file menu clear all the fields. Any help? I'll attach the code below.
    ====================================================
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    public class Message extends JFrame implements ActionListener {
         public void actionPerformed(ActionEvent evt) {
         text1.setText(" ");
         text2.setText("RE: ");
         text3.setText(" ");
         public Message() {
         super("Write a Message - by Kieran Hannigan");
         setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
         setSize(370,270);
         FlowLayout flo = new FlowLayout(FlowLayout.RIGHT);
         setLayout(flo);
         //Make the bar
         JMenuBar bar = new JMenuBar();
         //Make "File" on Menu
         JMenu File = new JMenu("File");
         JMenuItem f1 = new JMenuItem("New");f1.addActionListener(this);
         JMenuItem f2 = new JMenuItem("Open");
         JMenuItem f3 = new JMenuItem("Save");
         JMenuItem f4 = new JMenuItem("Save As");
         JMenuItem f5 = new JMenuItem("Exit");
         File.add(f1);
         File.add(f2);
         File.add(f3);
         File.add(f4);
         File.add(f5);
         bar.add(File);
         //Make "Edit" on menu
         JMenu Edit = new JMenu("Edit");
         JMenuItem e1 = new JMenuItem("Cut");
         JMenuItem e2 = new JMenuItem("Paste");
         JMenuItem e3 = new JMenuItem("Copy");
         JMenuItem e4 = new JMenuItem("Repeat");
         JMenuItem e5 = new JMenuItem("Undo");
         Edit.add(e5);
         Edit.add(e4);
         Edit.add(e1);
         Edit.add(e3);
         Edit.add(e2);
         bar.add(Edit);
         //Make "View" on menu
         JMenu View = new JMenu("View");
         JMenuItem v1 = new JMenuItem("Bold");
         JMenuItem v2 = new JMenuItem("Italic");
         JMenuItem v3 = new JMenuItem("Normal");
         JMenuItem v4 = new JMenuItem("Bold-Italic");
         View.add(v1);
         View.add(v2);
         View.add(v3);
         View.addSeparator();
         View.add(v4);
         bar.add(View);
         //Make "Help" on menu
         JMenu Help = new JMenu("Help");
         JMenuItem h1 = new JMenuItem("Help Online");
         JMenuItem h2 = new JMenuItem("E-mail Programmer");
         Help.add(h1);
         Help.add(h2);
         bar.add(Help);
         setJMenuBar(bar);
         //Make Contents of window.
         //Make "Subject" text field
         JPanel row2 = new JPanel();
         JLabel sublabel = new JLabel("Subject:");
         row2.add(sublabel);
         JTextField text2 = new JTextField("RE:",24);
         row2.add(text2);
         //Make "To" text field
         JPanel row1 = new JPanel();
         JLabel tolabel = new JLabel("To:");
         row1.add(tolabel);
         JTextField text1 = new JTextField(24);
         row1.add(text1);
         //Make "Message" text area
         JPanel row3 = new JPanel();
         JLabel Meslabel = new JLabel("Message:");
         row3.add(Meslabel);
         JTextArea text3 = new JTextArea(6,22);
         messagearea.setLineWrap(true);
         messagearea.setWrapStyleWord(true);
         JScrollPane scroll = new JScrollPane(text3,
                                  JScrollPane.VERTICAL_SCROLLBAR_ALWAYS,
                                  JScrollPane.HORIZONTAL_SCROLLBAR_NEVER);
         //SpaceLine
         JPanel spaceline = new JPanel();
         JLabel spacer = new JLabel(" ");
         spaceline.add(spacer);
         row3.add(scroll);
         add(row1);
         add(row2);
         add(spaceline);
         add(spaceline);
         add(row3);
         setVisible(true);
         public static void main(String[] arguments) {
         Message Message = new Message();
    }

    persiandude wrote:
    Topic: Need help with if, else, and which statements and loops.
    How would I display 60 < temp. <= 85 in java
    System.out.println("60 < temp. <= 85 in java");
    another question is how do I ask a question like want to try again (y/n) after a output and asking that everytime I type in yes after a output and terminate when saying No.Sun's [basic Java tutorial|http://java.sun.com/docs/books/tutorial/]
    Sun's [New To Java Center|http://java.sun.com/learning/new2java/index.html].Includes an overview of what Java is, instructions for setting up Java, an intro to programming (that includes links to the above tutorial or to parts of it), quizzes, a list of resources, and info on certification and courses.
    [http://javaalmanac.com|http://javaalmanac.com]. A couple dozen code examples that supplement [The Java Developers Almanac|http://www.amazon.com/exec/obidos/tg/detail/-/0201752808?v=glance].
    jGuru. A general Java resource site. Includes FAQs, forums, courses, more.
    JavaRanch. To quote the tagline on their homepage: "a friendly place for Java greenhorns." FAQs, forums (moderated, I believe), sample code, all kinds of goodies for newbies. From what I've heard, they live up to the "friendly" claim.
    Bruce Eckel's [Thinking in Java|http://mindview.net/Books/DownloadSites] (Available online.)
    Joshua Bloch's [Effective Java|http://www.amazon.com/Effective-Java-2nd-Joshua-Bloch/dp/0321356683/ref=pd_bbs_1?ie=UTF8&s=books&qid=1214349768&sr=8-1]
    Bert Bates and Kathy Sierra's [Head First Java|http://www.amazon.com/exec/obidos/tg/detail/-/0596004656?v=glance].
    James Gosling's [The Java Programming Language|http://www.bookpool.com/sm/0321349806].

  • Help with something simple

    Hey guys so I'm trying to write a quick program that should be no problem but I hit a wall and have no idea what's going wrong. The part of my program that isn't working is as follows: I'm accepting a String hexadecimal value as input that can be any number of characters long (for example "FF34CD"). I want to convert this to decimal so what I have done is parsed the input string and assigned each character to a slot in an array called hexArray. I then wrote a loop that will populate decimalArray with the corresponding decimal values for the hex info (i.e. 1=1, 2=2, A=10, B=11, and so on). What I don't understand is that the code works fine for an input that is one character long (i.e. "F"), but as soon as I try a longer input, the decimalArray does not get populated at all. I have tried everything I can think of to make this work and I can't seem to figure it out. Any thoughts?
    * Write a description of class FAT here.
    * @author (your name)
    * @version (a version number or a date)
    public class FAT
        // instance variables - replace the example below with your own
        private String[] hexArray;
        private int[] decimalArray;
        private String hexValue;
        int test;
         * Constructor for objects of class FAT
        public FAT(String hexValueIn)
            hexValue = hexValueIn;
            hexArray = new String[hexValue.length()];
            decimalArray = new int[hexValue.length()];
            test = 0;
         * An example of a method - replace this comment with your own
         * @param  y   a sample parameter for a method
         * @return     the sum of x and y
        public int convertDecimal()
            int result = 0;
            int arraySize = hexValue.length();
            for(int i = 0; i < arraySize; i++)
                String entry;
                entry = hexValue.substring(i,i+1);
                hexArray[i] = entry;
            for(int i = 0; i < arraySize; i++)
                if(hexArray[i] == "0")
                    decimalArray[i] = 0;
                else if(hexArray[i] == "1")
                    decimalArray[i] = 1;
                else if(hexArray[i] == "2")
                    decimalArray[i] = 2;
                else if(hexArray[i] == "3")
                    decimalArray[i] = 3;
                else if(hexArray[i] == "4")
                    decimalArray[i] = 4;
                else if(hexArray[i] == "5")
                    decimalArray[i] = 5;
                else if(hexArray[i] == "6")
                    decimalArray[i] = 6;   
                else if(hexArray[i] == "7")
                    decimalArray[i] = 7;
                else if(hexArray[i] == "8")
                    decimalArray[i] = 8;
                else if(hexArray[i] == "9")
                    decimalArray[i] = 9; 
                else if(hexArray[i] == "A")
                    decimalArray[i] = 10;
                else if(hexArray[i] == "B")
                    decimalArray[i] = 11;           
                else if(hexArray[i] == "C")
                    decimalArray[i] = 12;
                else if(hexArray[i] == "D")
                    decimalArray[i] = 13;
                else if(hexArray[i] == "E")
                    decimalArray[i] = 14;
                else if(hexArray[i] == "F")
                    decimalArray[i] = 15;
            return result;
    }

    Yeah, I'm sorry, I should have been more specific, I'm not actually looking at the returned value, I'm simply running the convertDecimal code and then inspecting the decimalArray (as I haven't gotten to the part where I return the decimal value because the decimalArray is not populating correctly).
    For some reason it populates completely fine when the input is "F" but not "FF".
    Additionally, here are the following things I have done to rule out some issues:
    - I put a simple counter to make sure that the loop is still running the appropriate amount of times when the input length is >=2. The loop does run.
    - I hardcoded the amount of times the loop should run, rather than using arrayLength, still didn't work.
    - I even completely hardcoded, within the loop, the subscript values for the two arrays (i.e. instead of hexArray(i) and decimalArray(i), I actually wrote in: hexArray[0], decimalArray[0], hexArray[1], decimalArray[1], and so on and it STILL did not work. For some reason, whenever the input is longer than 1 character, not one of the IF statements is returning true, even though it (obviously) should be - like I said I even harcoded it to say:
    if(hexArray[0] == "F")
         decimalArray[0] = 15;... and so on. And it returns false for the IF statement EVEN IF I inputted, for example "FFFFF" where every single character in the input is an F - how could that if statement possibly be coming back false? And why does it come back true when the input is just 'F'??? I hope this helps clear up the issue I'm having. And thanks in advance for the responses guys you're awesome!
    Edited by: 991431 on Mar 3, 2013 7:51 AM
    Edited by: 991431 on Mar 3, 2013 8:00 AM
    Edited by: 991431 on Mar 3, 2013 8:01 AM

  • Need help with a simple process with FTP Adapter and File Adapter

    I am trying out a simple BPEL process that gets a file in opaque mode from a FTP server using a FTP adapter and writes it to the local file system using a File Adapter. However, the file written is always empty (zero bytes). I then tried out the FTPDebatching sample using the same FTP server JNDI name and this work fine surprisingly. I also verified by looking at the FTP server logs that my process actually does hit the FTP server and seems to list the files based on the filtering condition - but it does not issue any GET or RETR commands to actually get the files. I am suspecting that the problem could be in the Receive, Assign or Invoke activities, but I am not able identify what it is.
    I can provide additional info such as the contents of my bpel and wsdl files if needed.
    Would appreciate if someone can help me with this at the earliest.
    Thanks
    Jay

    persiandude wrote:
    Topic: Need help with if, else, and which statements and loops.
    How would I display 60 < temp. <= 85 in java
    System.out.println("60 < temp. <= 85 in java");
    another question is how do I ask a question like want to try again (y/n) after a output and asking that everytime I type in yes after a output and terminate when saying No.Sun's [basic Java tutorial|http://java.sun.com/docs/books/tutorial/]
    Sun's [New To Java Center|http://java.sun.com/learning/new2java/index.html].Includes an overview of what Java is, instructions for setting up Java, an intro to programming (that includes links to the above tutorial or to parts of it), quizzes, a list of resources, and info on certification and courses.
    [http://javaalmanac.com|http://javaalmanac.com]. A couple dozen code examples that supplement [The Java Developers Almanac|http://www.amazon.com/exec/obidos/tg/detail/-/0201752808?v=glance].
    jGuru. A general Java resource site. Includes FAQs, forums, courses, more.
    JavaRanch. To quote the tagline on their homepage: "a friendly place for Java greenhorns." FAQs, forums (moderated, I believe), sample code, all kinds of goodies for newbies. From what I've heard, they live up to the "friendly" claim.
    Bruce Eckel's [Thinking in Java|http://mindview.net/Books/DownloadSites] (Available online.)
    Joshua Bloch's [Effective Java|http://www.amazon.com/Effective-Java-2nd-Joshua-Bloch/dp/0321356683/ref=pd_bbs_1?ie=UTF8&s=books&qid=1214349768&sr=8-1]
    Bert Bates and Kathy Sierra's [Head First Java|http://www.amazon.com/exec/obidos/tg/detail/-/0596004656?v=glance].
    James Gosling's [The Java Programming Language|http://www.bookpool.com/sm/0321349806].

  • Need help with a simple basketball game.

    Hi im new here and I need help with making this simple basketball game.
    Im trying to recreate this game from this video. Im not sure if he is using as2 or as3
    Or if anyone could help me make a game like this or direct me to a link on how to do it It would be greatly appreciated.

    If you couldn't tell whether it is AS2 or AS3, it is doubtful you can turn it from AS2 into AS3, at least not until you learn both languages.  There is no tool made that does it for you.

  • Help with ABAP Structure to XML - Simple Transformation

    Hi guys,
    I need help with a Simple Transformation. I am trying to convert a structure in ABAP to XML String but i ma getting short dumps...
    Can any of you help.
    Thanks in advance.
    *& Report  ZTESTXML
    REPORT  ZTESTXML.
    class demo DEFINITION.
       PUBLIC SECTION.
       CLASS-METHODS main.
       ENDCLASS.
       CLASS demo IMPLEMENTATION.
         method main.
           data : begin of account,
                    partner type bu_partner,
                    primary(1),
                    update(3),
                    email(50),
                    memberid(4),
                    telephone(12),
                    fax(10),
                    dept(20),
                    end of account.
            data : xmlstr type xstring.
                    account-partner = '12345'.
                    account-primary = 'N'.
                    account-update = 'Yes'.
                    account-email = 'zz at hotmail.com'.
                    account-memberid = '555'.
                    account-telephone = '123-448-6710'.
                    account-fax = '345-123-7899'.
                    account-dept = 'Info Systems'.
                    call TRANSFORMATION ztest_inttable
                                        SOURCE account = 'account'
                                        result XML xmlstr.
           call FUNCTION 'DISPLAY_XML_STRING'
               EXPORTING xml_string = xmlstr.
           ENDMETHOD.
           ENDCLASS.
           start-of-SELECTION.
             demo=>main( ).
    Transformation
    <?sap.transform simple?>
    <tt:transform xmlns:tt="http://www.sap.com/transformation-templates">
      <tt:root name="account"/>
      <tt:template>
        <IGT_CRM_AccountInfo>
          <Account>
            <tt:ref name=".account">
              <tt:attribute name="Id" value-ref="PARTNER"/>
              <tt:attribute name="Primary" value-ref="primary"/>
              <tt:attribute name="Update" value-ref="update"/>
              <Contact>
                <tt:attribute name="EMail" value-ref="email"/>
                <tt:attribute name="Member Id" value-ref="memberid"/>
              </Contact>
              <Communications>
                <tt:attribute name="Telephone" value-ref="telephone"/>
                <tt:attribute name="Fax" value-ref="fax"/>
              </Communications>
              <IGT>
                <tt:attribute name="Department" value-ref="dept"/>
              </IGT>
            </tt:ref>
          </Account>
        </IGT_CRM_AccountInfo>
      </tt:template>
    </tt:transform>
    Dump message
    An exception occurred that is explained in detail below.
    The exception, which is assigned to class 'CX_ST_REF_ACCESS', was not caught in
    procedure "MAIN" "(METHOD)", nor was it propagated by a RAISING clause.
    Since the caller of the procedure could not have anticipated that the
    exception would occur, the current program is terminated.
    The reason for the exception is:
    The goal was to access variable "PARTNER". However, this access was not
    possible.

    to convert abap itab or variable into xml string use ABAP key word call transformation.
    call transformation (`ID`)
                source output = itab[]
                result xml xml_out.
    where itab is your internal table or any abap variable.
    xml_out is type string which will hold the resulting xml.
    ID is the transformation program. if you wanto use your own transformation, use your XSLT or ST program there.
    Raja

  • Help with simple script

    I was wondering if someone could help me with a simple bit of action script 3. I need to make a movie clip (single_mc) disappear when the user clicks on the mouse (stop_btn). Here’s what I have so far.
    function setProperty(event:MouseEvent):void
    single_mc.alpha=0;
    stop_btn.addEventListener(MouseEvent.CLICK, setProperty);
    Also I was wonder if you could recommend an Action script 3 book for me. I would like one that is not a training book, but has situations and then the script written out. For example: I click a button and a movie symbol disappears from the stage. I am a graphic artist, that from time to time, needs simple interaction in flash, but cant justify the time to learn the script.
    Thanks for your time

    use the snippets panel to help with you with sample code for basic tasks.
    function setProperty(event:MouseEvent):void
    single_mc.visible=false;
    stop_btn.addEventListener(MouseEvent.CLICK, setProperty);

  • Help with a simple program.

    I need some help writing a simple program. Can anybody help??
    thanks to all.
    2. HTML Java Source Code Reserved Word Highlighter
    Write a program that inputs a Java source code file and outputs a copy of that file with Java keywords surrounded with HTML tags for bold type. For example this input:
    public class JavaSource
    public static void main ( String[] args )
    if ( args.length == 3 )
    new BigObject();
    else
    System.out.println("Too few arguments.");
    will be transformed into:
    <B>public</B> <B>class</B> JavaSource
    <B>public</B> <B>static</B> <B>void</B> main ( String[] args )
    <B>if</B> ( args.length == 3 )
    <B>new</B> BigObject();
    <B>else</B>
    System.out.println("Too few arguments.");
    In a browser the code will look like this:
    public class JavaSource
    public static void main ( String[] args )
    if ( args.length == 3 )
    new BigObject();
    else
    System.out.println("Too few arguments.");

    Here is something that may get you started...
    import java.io.*; 
    import java.util.*; 
    public class HtmlJava{
         public static void main(String arg[]){
              if(arg.length!=1){
                   System.out.println("Usage java HtmlJava sourceFile");       
              else
                   new HtmlJava(arg[0]);
         HtmlJava(String source){
              try{
                   BufferedReader sourceReader=new BufferedReader(new InputStreamReader(new FileInputStream(source)));
                   BufferedWriter writer=new BufferedWriter(new OutputStreamWriter(new FileOutputStream(source+"Html.txt")));  
                   Vector keywords=new Vector();
                   addKeywords(keywords);
                   String line;
                   StringTokenizer tokenizer=null;
                   String word;
                   while((line=sourceReader.readLine () )!=null){
                        tokenizer=new StringTokenizer(line);
                        while(tokenizer.hasMoreTokens()){
                             word=tokenizer.nextToken();
                             if(keywords.contains(word)){
                                  writer.write(""+word+" ");
                             else{
                                  writer.write(word+" ");
                        writer.write("\r\n");
                   writer.close();
                   sourceReader.close(); 
                   System.out.println("Output File written to "+source+"Html.txt"); 
              catch(Exception ex){
                   ex.printStackTrace();      
         private void addKeywords(Vector keywords){
              keywords.addElement ( "abstract");
              keywords.addElement( "boolean");
              keywords.addElement( "break");
              keywords.addElement( "byte");
              keywords.addElement( "byvalue");
              keywords.addElement( "case");
              keywords.addElement( "cast");
              keywords.addElement( "catch");
              keywords.addElement( "char");
              keywords.addElement( "class");
              keywords.addElement( "const");
              keywords.addElement( "continue");
              keywords.addElement( "default");
              keywords.addElement( "do");
              keywords.addElement( "double");
              keywords.addElement( "else");
              keywords.addElement( "extends");
              keywords.addElement( "false");
              keywords.addElement( "final");
              keywords.addElement( "finally");
              keywords.addElement( "float");
              keywords.addElement( "for");
              keywords.addElement( "future");
              keywords.addElement( "generic");
              keywords.addElement( "goto");
              keywords.addElement( "if");
              keywords.addElement( "implements");
              keywords.addElement( "import");
              keywords.addElement( "inner");
              keywords.addElement( "instanceof");
              keywords.addElement( "int");
              keywords.addElement( "interface");
              keywords.addElement( "long");
              keywords.addElement( "native");
              keywords.addElement( "new");
              keywords.addElement( "null");
              keywords.addElement( "operator");
              keywords.addElement( "outer");
              keywords.addElement( "package");
              keywords.addElement( "private");
              keywords.addElement( "protected");
              keywords.addElement( "public");
              keywords.addElement( "rest");
              keywords.addElement( "return");
              keywords.addElement( "short");
              keywords.addElement( "static");
              keywords.addElement( "super");
              keywords.addElement( "switch");
              keywords.addElement( "synchronized");
              keywords.addElement( "this");
              keywords.addElement( "throw");
              keywords.addElement( "throws");
              keywords.addElement( "transient");
              keywords.addElement( "true");
              keywords.addElement( "try");
              keywords.addElement( "var");
              keywords.addElement( "void");
              keywords.addElement( "volatile");
              keywords.addElement( "while");
    }Hope it helped

Maybe you are looking for

  • Error in updating OBNK Table ( Bank Statements and Reconciliations,Manual)

    PLease advise , Bank Statements and Reconciliations,Manual Reconciliation Client is receiving the following message: Error in updating OBNK Table Edited by: Philip Eller on May 20, 2008 9:03 AM

  • Iphone 5 from Dubai not working in INDIA. Call failed

    I bought 3 Iphone5 from Dubai out of it 2 are working on Vodafone India(Call & 3G data)  but the Third iphone 5(3G Data only) on vodafone. i have managed to cut sim into NANO sim they are working on other two Iphone5 but not on last one. i can use DA

  • Document date in MRKO

    Hello All, Does anybody know how to change the document and posting date in MRKO transaction? I would like to be able to post using different dates. Is it possible? How? Thanks, Michel Khouri

  • Change colors of entire row according to another

    Just to keep you guys busy: I have a crosstab layout and I want to change the color of the entire row according to one column, is that possible??

  • IPhone 4 completely unstable after update to ios 5.0.1

    Hello everyone,, I just updated my iPhone 4 from ios 5 to ios 5.0.1. Unfortunatly right after the update the screen in starting to flickr non-stop. with the apple logo and the loading bar stuck in the middle of the screen like a background. regarding