Press enter to continue...

hi all,
in my server /client model the clients log on and register ina vector class..since im working on distributed computing, time is important. so in my simulation, i wait for all the clients to log on and after i press enter, the server sends out the jobs.. this is how im doing..
static String name
System.out.println("press enter to continue");
try
name = br.readLine();
     }     catch(IOException e)
               System.out.println(e);
this does work fine. but depending upon number of clients, i have press enter key so many times. how to change this, so that by pressing just once, it is updated in all the clients.? or is there a better way to do this? using may be datastreaminput(i had read it but have forgotten the website).
thank you
ls

Don't know if this is actual anymore but still (I'm in a situation when I can access the net only on weekends if I'm lucky)...
You still ask the user to "press enter to continue" when ever you add a client since the codes for those two things are in the same place. You should move the code that asks for "enter" outside that method completely, that is:/* some code... */
public void addClient(frequencies obj) {
clientno = track ;
track++;
Clients.addElement(obj);
System.out.println("client added");
/* getting a handle to the callback object */
f[clientno] = (frequencies)Clients.elementAt(clientno);
client++;
sendout(client -1);
}//end of addclient
/* some more code... */
// call addClient in a loop here
System.out.println("press enter to continue");
try {
name = br.readLine();
} catch(IOException e) {
System.out.println(e);
/* and even more code... */

Similar Messages

  • Selected boot image did not authentica​te. Press enter to continue

    I just removed the stock HDD that came with my M4-1015x and now I'm trying to install windows 7 to the SSD that I replaced it with. However, upon boot up I get the message "Selected boot image did not authenticate. Press <enter> to continue" when the laptop attempts to read the OS from the disc. I've never seen this before... any help? (It's a legitimate DVD copy of Windows 7)
    Thanks.
    This question was solved.
    View Solution.

    I fixed it. Had to disable secureboot and enable legacy boot mode to get it to run.

  • How to pause, say press enter to continue...

    Hi all,
    is there any scripts or documents for pause, say press enter to continue...?
    thanks
    andrew

    Try this:
    try
    byte[] b = new byte[2];
    System.in.read (b);
    } catch (IOException ex) {}

  • Message d'erreur "selected boot image did not authenticate. Press enter to continue.

    Jai le Message d'erreur "selected boot image did not authenticate. Press <enter> to continue."
    Jai vus dautre sujet comme cellui-ci mais moi il m'est impossible douvrir f10 poir desactiber le secure boot
    Merci de vos reponse

    Hi los,
    Thank you for visiting our English HP Support Forum. We are only able to reply to posts written in English. To insure a quick response it would be advisable to post your question in English. The following links are here to assist you if you prefer to post in the following Language Forum.
    English:                                 http://h30434.www3.hp.com
    Spanish:                               http://h30467.www3.hp.com
    French:                                 http://h30478.www3.hp.com
    Portuguese:                       http://h30487.www3.hp.com
    German:                              http://h30492.www3.hp.com
    Korean:                                http://h30491.www3.hp.com/t5/community/communitypage
    Simplified Chinese:         http://h30471.www3.hp.com/t5/community/communitypage
    Regards,
    George

  • How to use Press Enter to Continue

    Hello
    how do i use press enter to continue in my programs
    can i plz have the code

    K here is my code
    import java.io.*;
    public class asn3
        public static void main (String [] args) throws Exception
            DataInput keyboard = new DataInputStream (System.in);
            int num = 0;
            String temp;
            String [] ques;
            String [] a, b, c, d, e;
            String [] ans;
            ques = new String [5];
            ques [0] = "(1) Which one of the following is an input device?";
            ques [1] = "(2) Which one of the following is an output device?";
            ques [2] = "(3)What does CPU stand for?";
            ques [3] = "(4)How many bytes in a megabyte";
            ques [4] = "(5)How many bytes in a gigabyte ?";
            a = new String [5];
            a [0] = "a) Printer";
            a [1] = "b) Monitor";
            a [2] = "c) Mouse";
            a [3] = "d) Speaker";
            b = new String [4];
            b [0] = "a) Mouse";
            b [1] = "b) Keyboard";
            b [2] = "c) Scanner";
            b [3] = "d) Speaker";
            c = new String [4];
            c [0] = "a) It does not stand for anything";
            c [1] = "b) Centeral Processing Unit";
            c [2] = "c) DUH!!!";
            c [3] = "d) City Power Unit";
            d = new String [4];
            d [0] = "a) 1";
            d [1] = "b) 1024";
            d [2] = "c) 4096";
            d [3] = "d) 1,048,576";
            e = new String [4];
            e [0] = "a) about 1 thousand";
            e [1] = "b) about 1 million";
            e [2] = "c) about 1 billion";
            e [3] = "d) about 1 trillion";
            ans = new String [5];
            ans [0] = "c";
            ans [1] = "d";
            ans [2] = "b";
            ans [3] = "d";
            ans [4] = "d";
            System.out.println ("\t\t\tWelcome to the quiz \n");
            System.out.println (ques [0] + "\n\n" + a [0] + "\n" + a [1] + "\n" + a [2] + "\n" + a [3]);
            System.out.print ("\nanswer : ");
            temp = keyboard.readLine ();
            if (temp.equals (ans [0]))
                System.out.println ("\n\nCorrect!!! \n");
                num = num + 1;
            else
                System.out.println ("\n\nWrong!!!\n\n");
            System.out.println (ques [1] + "\n\n" + b [0] + "\n" + b [1] + "\n" + b [2] + "\n" + b [3]);
            System.out.print ("\nanswer : ");
            temp = keyboard.readLine ();
            if (temp.equals (ans [1]))
                System.out.println ("\n\nCorrect!!! \n");
                num = num + 1;
            else
                System.out.println ("\n\nWrong!!!\n\n");
            System.out.println (ques [2] + "\n\n" + c [0] + "\n" + c [1] + "\n" + c [2] + "\n" + c [3]);
            System.out.print ("\nanswer : ");
            temp = keyboard.readLine ();
            if (temp.equals (ans [2]))
                System.out.println ("\n\nCorrect!!! \n");
                num = num + 1;
            else
                System.out.println ("\n\nWrong!!!\n\n");
            System.out.println (ques [3] + "\n\n" + d [0] + "\n" + d [1] + "\n" + d [2] + "\n" + d [3]);
            System.out.print ("\nanswer : ");
            temp = keyboard.readLine ();
            if (temp.equals (ans [3]))
                System.out.println ("\n\nCorrect!!! \n");
                num = num + 1;
            else
                System.out.println ("\n\nWrong!!!\n\n");
            System.out.println (ques [4] + "\n\n" + e [0] + "\n" + e [1] + "\n" + e [2] + "\n" + e [3]);
            System.out.print ("\nanswer : ");
            temp = keyboard.readLine ();
            if (temp.equals (ans [4]))
                System.out.println ("\n\nCorrect!!! \n");
                num = num + 1;
            else
                System.out.println ("\n\nWrong!!!\n\n");
              System.out.println ("--------------------------------------------------");
            System.out.println ("You answered " + num + " out of 5 questions correctly\n\n");
            if (num >= 5)
                System.out.println ("Grade A+ : You are Awesome\n\n ");
            else if ((num >= 4) && (num < 5))
                System.out.println ("Grade A : You did Great\n\n ");
            else if ((num >= 3) && (num < 4))
                System.out.println ("Grade C : You did Okay\n\n ");
            else
                System.out.println ("Grade F : You did Poorly\n\n ");
    }just wanted to add press Enter to continue feature in the program
    any more hints?
    btw i have no clue about scanner class

  • Press Enter to Continue Movie

    Hi, I'm still new to using Flash and Actionscript and I was
    wondering if anyone could provide me with a quick code to get the
    Flash movie to stop on a certain frame and the continue when the
    user hits ENTER. I've tried experimenting with Actionscript and
    I've gotten the frame to stop/play but I keep getting errors when I
    try to code the push enter event. Any help would be
    appreciated.

    Put an invisible button on the stage (create a button with no
    content just a small hit area). Attach this code to the button:
    on(keyPress "<Enter>"){
    play();

  • Pressing ENTER in Command Prompt to solve hanging

    Hi,
    Does anyone know why sometimes Java hangs, unless you press ENTER in the
    Command Prompt for Windows 2K? After pressing ENTER it continues execution.
    It happens with WebLogic sometimes too. It will not print anything on the
    console until I press ENTER.
    I'm sure lots of Java developers have experienced this weird problem.
    Thanks,
    Duke
    [email protected]

    That is what we call a "feature" of an enterprise-class OS ;-)
    Peace,
    Cameron Purdy
    Tangosol Inc.
    Tangosol Coherence: Clustered Coherent Cache for J2EE
    Information at http://www.tangosol.com/
    "Chad McDaniel" <[email protected]> wrote in message
    news:[email protected]..
    On windows machines be very careful to turn off the "mark" option in
    the shell preferences. It can halt the server.
    Daniel Hoppe <[email protected]> writes:
    Hi,
    because you marked something in the command prompt. Marking stops
    execution. Enter means 'copy' and continues execution...
    Daniel
    -----Original Message-----
    From: Duke Nguyen [mailto:[email protected]]
    Posted At: Thursday, December 13, 2001 3:16 AM
    Posted To: ejb
    Conversation: pressing ENTER in Command Prompt to solve hanging
    Subject: pressing ENTER in Command Prompt to solve hanging
    Hi,
    Does anyone know why sometimes Java hangs, unless you press
    ENTER in the
    Command Prompt for Windows 2K? After pressing ENTER it
    continues execution.
    It happens with WebLogic sometimes too. It will not print
    anything on the
    console until I press ENTER.
    I'm sure lots of Java developers have experienced this weird problem.
    Thanks,
    Duke
    [email protected]

  • I need an app or software that records the date/time each time a write something and press enter. This needs to be quick so I can continue writing right after I press enter, and the date/time is inserted for each word. Does this sort of software exist?

    I need an app or software that records the date/time each time a write something and press enter. This needs to be quick so I can continue writing right after I press enter, and the date/time is inserted for each word. Imagine a spreadsheet - each time a write something in a cell and press enter to go into the next cell, I need the app/software to automatically insert the corresponding dat and time. Does this sort of software exist?

    No one here is going to do anything about it. Send feedback to Apple.
    http://www.apple.com/feedback/ipad.html
    Basic troubleshooting steps. 
    17" 2.2GHz i7 Quad-Core MacBook Pro  8G RAM  750G HD + OCZ Vertex 3 SSD Boot HD 

  • Running commands with powershell - randomly need to press Enter for the command to continue

    Hi,
    I have noticed quiet a few times now that when i run some commands in a powershell window, the execution seems to hang and if i press enter the rest of the command is executed.
    It does it for such as simple thing as
    xcopy \\source \\dest
    repadmin /syncall /Adep
    The commands are executed but i need to press enter at some point (and multiple times) for the command to complete.
    Anyone have seen this kind of behavior?

    Something very similar to this came up recently, so I'll throw it out there.  Do you have "QuickEdit Mode" enabled for your PowerShell console?  If so, when you click your mouse somewhere in the window, it starts to select text to be copied or
    pasted, and your window title will change from (for example) "Windows PowerShell" to "Select Windows PowerShell".  When you press enter, you copy whatever was highlighted to the clipboard, and the console goes back to normal.

  • After the update, pressing Enter no longer works to go to a URL, nor does it work in the Google Search bar thing.

    Pretty much what the question says. I updated to the latest Firefox, and now this really irritating thing happens.... It happens lots of places too. Some specific things:
    * Clicking on the address bar at all does not bring up the little flashing cursor thing, and generally gives me no indication that I've actually clicked on the URL. Same with that little google search thing in the upper right.
    * Most frustratingly, when I press enter after putting in a URL, it won't even go to the site.
    * After getting annoyed at both of those things, I try to type in something on a website, and though the URL stays the same, it starts dropping down a lot of suggestions from my history.
    * Lastly, when I'm doing my crosswords on Washington Post and I switch to a different tab to type something on there, it doesn't switch my typing thing over - it stays on the crossword, typing things into that rather than into the typing field I clicked on to start typing in.
    So, yeah, this is highly annoying, and I'd love for any help for these issues...
    I did look at the FAQs, and they said something about the AVG SafeSearch thing causing one of my problems, but I don't have that extension, so it's definitely not that!

    The AVG Safe Search extension can cause problems with the Enter key not working in the location bar.

  • When i type in my correct password on the login screen and press enter it just goes to a blue screen for a few seconds then goes back to the same login screen again, please i need help?

    When i type in my correct password on the login screen and press enter it just goes to a blue screen for a few seconds then goes back to the same login screen again, please i need help?

    You can take some of the steps here, #4, #5 or even trying a #18
    Step by Step to fix your Mac
    but I suspect your going to first have to create a data recovery drive
    Create a data recovery, undelete boot drive
    to get your data off the machine,
    then do a #20 to eliminate the bad sectors as that's why your getting the "pinwheel" it's getting a delay reading from the drive, right when your trying to log in too, what a bad spot for it to happen.
    Step by Step to fix your Mac

  • Can someone help me understand why the search engine will not do anything when I click the search icon or press enter, and why new windows won't open when I click on a link that should open one?

    When I type something in the search engine at the right hand corner of the screen it will not allow the search to take place. What I mean is I either click the icon or press enter and nothing happens. I would understand it better if it at the very least gave me a error message. I have also noticed that things like the opening of a new window via a link will not work. An example is I was just on www.walmart.com and when I clicked on an image in order to see a larger one no window opened. I also recently noticed that when I had a lot of tabs open the shortcut menus and menus in general did not load completely or really at all keeping me from saving the pages as bookmarks. I know this could be from low internet speed, a lot of tabs etc..., but I've had many more tabs open than I had then and it worked. Plus all I did was delete or close one tab and suddenly it worked. I then recovered the tab and it still worked even though I was back at the original amount of tabs. I have the latest version of firefox, not counting the beta, and I don't know of any way to solve the two main problems.

    Start Firefox in [[Safe Mode]] to check if one of the add-ons is causing the problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).
    * Don't make any changes on the Safe mode start window.
    See:
    * [[Troubleshooting extensions and themes]]
    * [[Troubleshooting plugins]]
    If it does work in Safe-mode then disable all extensions and then try to find which is causing it by enabling one at a time until the problem reappears.
    * Use "Disable all add-ons" on the [[Safe mode]] start window to disable all extensions.
    * Close and restart Firefox after each change via "File > Exit" (Mac: "Firefox > Quit"; Linux: "File > Quit")

  • Selection screen field is not populated without pressing "Enter"

    Hello All,
    I am calling a report from module pool using SUBMIT statement. I have defined a selection screen as subscreen on module pool screen. On this selection screen i have a select option S_BUKRS. When I input company code 1000 and just press execute button on module pool, it is taking me to the report output. But S_BUKRS is not filled before the submit statement and hence report is executing as if S_BUKRS is initial.
    I put a breakpoint and saw that the field S_BUKRS is not filled before calling the repot.
    I re-ran the transaction (module pool) and this time after inputting 1000 in S_BUKRS I pressed enter and then pressed execute button. Now the value is transferred to report since S_BUKRS[] is filled.
    Do I need to press enter key after inputting the values on the selection screen everytime; before pressing the execute button?
    What could be the issue and how can I resolve it?
    I am calling the report in PAI of module pool using statement SUBMIT ZREPORT1 WITH s_bukrs IN s_bukrs AND RETURN.
    Thanks,
    Sandeep

    sandeep akula wrote:
    Hello All,
    > I am calling a report from module pool using SUBMIT statement. I have defined a selection screen as subscreen on module pool screen. On this selection screen i have a select option S_BUKRS. When I input company code 1000 and just press execute button on module pool, it is taking me to the report output. But S_BUKRS is not filled before the submit statement and hence report is executing as if S_BUKRS is initial.
    > I put a breakpoint and saw that the field S_BUKRS is not filled before calling the repot.
    > I re-ran the transaction (module pool) and this time after inputting 1000 in S_BUKRS I pressed enter and then pressed execute button. Now the value is transferred to report since S_BUKRS[] is filled.
    > Do I need to press enter key after inputting the values on the selection screen everytime; before pressing the execute button?
    > What could be the issue and how can I resolve it?
    > I am calling the report in PAI of module pool using statement SUBMIT ZREPORT1 WITH s_bukrs IN s_bukrs AND RETURN.
    > Thanks,
    > Sandeep
    I believe, you should be able to caputre the value of S_BUKRS in AT SELECTION-SCREEN event even if the user executes the program with out hitting Enter key. Make sure that you are including the CALL SUBSCREEN <area> statement in the PAI as the first statement.
    -Rajesh.

  • After upgrade from 34 to 35, control click still opens new tab but new tab won't load upon selection. i have to click address and press enter or click go

    I've used Firefox for many years, I really like it and have been readily recommending it to others.
    However after finally upgrading to 35.0.1 from 34.x I now have a very annoying and time-consuming issue.
    So much so that I'm thinking of attempting a downgrade!
    I didn't really want to upgrade but Firefox kept bothering me and I inadvertently accepted. Is there a way to switch this upgrade reminder off?
    Anyway, previously I would Ctrl-click a link and it would open a new tab but not jump to it. It would remain unloaded until I clicked it. Then it would load as normal.
    After the upgrade, I Ctrl-click a link and it still opens a new unloaded tab. So far, so good. Now however, when I click the new unloaded tab, it just sits there and does nothing. I have to click the URL in the address bar and either press <Enter> or click the 'Go' arrow.
    I use this feature sometimes 100s of times a day so this is extremely annoying as it adds considerable time and extra clicks to each new link I click.
    I'm wondering if it could be a problem with one of my plugins. Can I temporarily disable them all at once to see if that's it?
    I will try disabling the tab related plugins.
    I've tried toggling 'Don't load tabs until selected' on the Tabs page from Tools menu, Options.
    Any help would be thoroughly appreciated as I would like to return to being a Firefox Fan

    It is unlikely this issue is to do with Firefox upgrading. Firefox 36 will come out any day soon you should then be on that rather than considering an outdated Firefox 34 which is now not secure, and not supported.
    * See don't [[Install an older version of Firefox]]
    You have not listed your plugins, and Yes you could try using Firefox's add-on manager to make sure they are all set as click to activate or even temporarily set as never activate.
    I am not familiar with the add-on
    * UnloadTab 0.24.7 https://addons.mozilla.org/en-US/firefox/addon/unloadtab/
    That certainly may be part of the problem try deactivating that with Firefox's addon manager. For all I know this may be the intended behaviour of that addon.
    Also troubleshoot the issue with Firefox's safe mode, remembering that does NOT disable plugins you will still need to do that manually.
    * [[Troubleshoot Firefox issues using Safe Mode]]
    Please post back with how you get on and what you have tried, Including upgrading to Firefox 36 when that is available.
    [https://www.mozilla.org/en-US/firefox/releases/ Release notes]
    * [https://www.mozilla.org/en-US/firefox/35.0.1/releasenotes/ Fx35.0.1 release notes]
    ** The pre release notes for Fx 36 [https://www.mozilla.org/en-US/firefox/36.0beta/releasenotes/ (beta)]
    ** Likely link to new version fx36 release notes https://www.mozilla.org/en-US/firefox/36.0/releasenotes/

  • How can i display the values in a table when i press enter

    hi,
    I have three text boxes and a table with three columns in a jsp page.When i keyin some values in the text boxes and press Enter these values should be dispalyed in the three columns of the table.When once again if i key in the text boxes with some other values these values should also be displayed in the table columns in another row.Can it be done.Pls help me.Hoping for a reply.
    Thanks
    Naveen

    hi
    just go through the Code below:
    this helps you but this works in IE only.
    <html>
    <head>
    <script language="javascript">
    <!--
         function show(frm) {
              Show.innerText = frm.desc.value;
         } // closing the function show()
    //-->
    </script>
    </head>
    <form name="testform">
    <textarea name="desc" rows="3" cols="20"></textarea>
    <input type="button" name="buttsub" value="Submit" onClick="javascript:show(this.form)">
    <br>
    <table width="500">
    <tr><td bgcolor="#e6e6e6">
    <div id="Show"> </div>
    </td>
    </tr>
    </table>
    </form>
    </html>
    Cheers
    rambee

Maybe you are looking for