Quick help with IF statment

I am trying to do an IF-OR statement and I feel like I am clueless. Can someone let me know what the problem is?
if (getName.equals("Jim")) || (getName.equals("Robert")) {
name = "Smith";
else{
name = "Jones";
Thanks.

Match the parentheses:
if ((getName.equals("Jim")) || (getName.equals("Robert"))) {
name = "Smith";
else{
name = "Jones";
That should do it.

Similar Messages

  • Quick help with css display in IE7

    Hi, I haven't been on this forum in ages - I have a slight display glitch would love some help with:
    http://magma.ie/magmablog-html/index.html
    It looks great in the latest and greatest browser (IMHO!): - firefox 3.5.6
    http://cl.ly/17cD
    but IE7 pops the search field in the sidebar off to the right, at least, according to browsershots.org
    http://cl.ly/1A1f
    Thanks, H

    It looks OK in IE8 but IE7 is having trouble with the #Sidebar width.
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists
    http://alt-web.com/
    http://twitter.com/altweb
    http://alt-web.blogspot.com

  • Need some quick help with redoing a website

    Hi, I did my website done in iWeb in 2008, published it, and have it hosted by GoDaddy. I want to take it offline for now and design a new 'under construction' site, but there is a chance that I might want to still go back to the original version.
    I see the current 'Domain' in Home Folder>Library>Application Support>iWeb.
    Can I just redo my site (still working in pre-2008 iWeb), publish it, and if I need to, use the old 'Domain' to revert to my current website?
    If yes, how do I do that....and, if 'no', what should I do?
    Thanks!

    Hi and thanks. To reply....
    I published the website in iWeb and it is on my MobleMe. It was done in iWeb v 1.1.2, and I have not upgraded iLife on the computer that I designed the website on, as I feared losing some/all of it in an upgrade.
    I do, however, pay GoDaddy for my corporate URL AND hosting....which I suspect is the forwarding and not 'hosting' per se....but on my Hosting account on GoDaddy it does say 'Shared Hosting'.
    I do not want to 'overwrite' my current site just yet, as I am uncertain about the next one's content or the time to do it the way I envision it. What I want to do is SAVE my current site in case I want it back and, in the meantime, put up a page that says Under Construction. Can you help with that?
    Much appreciated

  • Quick help with dual booting

    I have hopped around on different distros and I found that Archlinux would be the best solution for me.  However, I need help with dual booting Archlinux and Vista as I will need Vista around for one program and a game that do not work with any Linux distro that I have tried.  I have not done a text based install before, I have only used newbie distros but I want to move on to Archlinux. 
    I will only need one partition for Vista and one for Arch.  I believe I can achieve the goal of dual booting them by shrinking the vista partition, and then installing Arch in the remaining space and use GRUB to boot the necessary partitions when my laptop is powered on.  This works with Ubuntu, so I assume it shall be the same basic concept with Arch.  I can follow the instructions on installing, and the installation is easier than I had expected it to be.  I have one question, how would I go about using the above technique that I mentioned during the install?  I would like to know how to do it correctly, I cannot risk messing up Vista.  I'm fifteen and my dad would be very frustrated if I did mess up Vista.  I would appreciate some specific instructions, because I really like Arch from what I have read.  I also look forward to being an active member in the community as well if all goes well.

    Welcome!
    Another young one I see! I'm currently 17, however I started using linux when I was 13 (8th grade year).
    You can resize the vista partition by using gparted. You can download the gparted livecd from there website (http://gparted.sourceforge.net/download.php). I do not know specific directions, but it is pretty obvious how to resize, and if you need help you can probably google something like "resize partition gparted". I WARN YOU that you do risk data loss resizing the partition. I don't believe the risk is high, but it still there, so backup any important data that you may have in case something goes wrong!!
    Do you have your own computer that you can experiment on? That might be a safe option than using your dads. I am been fortunate to have hand-me-down systems, but when I was young I made my dad angry quite a few times "experimenting!"
    If your dad's system has enough juice, you may want to consider install arch in a virtual machine to get idea of however thing works. Following the Beginners Guide on the wiki will be you best bet for a successful and well configured machine (http://wiki.archlinux.org/index.php/Beginners_Guide). If you really want to play it safe you can even go as far as install windows in a virtual machine, resizing the partition, and installing arch in the same virtual machine.
    I hate to say this, but if you absolutely can not mess up vista, I would advice against installing any other OS and messing with the partition scheme. As whenever you mess with the partitions you run a risk of messing up Vista (or any other os for that matter). If you don't already have your own computer which you can tinker with, it might not be a bad idea to look at getting one. They are becoming cheap, you can build one for about $300-$400USD, or buy one for probably around $400.
    Hope this helps a bit...

  • Quick help with flash and html

    Hi folks,
    just a quick query that i'm sure someone out there will know
    the answer to (or at least i'm hoping someone will)
    I've been working on a new site (first attempt so be gentle
    with any criticism please!!)
    I used fireworks8 to create a navmenu and it works a treat,
    however i also have flash on some of the pages, and the fireworks
    submenus don't seem to like showing up over the flash!
    see
    http://www.gammies.co.uk/construction.asp
    for what i mean. the nav links to construction, groundcare and
    recreational don't show becuase of the flash. I was trying to see
    if there was some option to send the flash to the back of the page
    as such so that the navmenu was on top but couldn't get it, and i'm
    no sure what i'd have to do code wise to change it (if it's a code
    issue). By the way it does it in both firefox and IE
    All help greatly appreciated..
    Thanks
    Chris

    All Active content on a page will always rise to the top, so
    to speak,
    including Flash, certain form elements, Java applets, and
    Active X controls.
    This means that each of these will poke through layers. There
    is not a good
    cross-browser/platform reliable way to solve this issue, but
    if you can be
    confident in your visitors using IE 5+ or NN6+, then you can
    use the Flash
    wmode parameter (however, Safari does not support this
    properly!).
    Adobe articles:
    http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=tn_15523
    http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=tn_14201
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    ==================
    "[email protected]" <[email protected]>
    wrote in message
    news:foc4db$2nh$[email protected]..
    > Hi folks, just a quick query that i'm sure someone out
    there will know
    > the
    > answer to (or at least i'm hoping someone will) I've
    been working on a
    > new
    > site (first attempt so be gentle with any criticism
    please!!) I used
    > fireworks8 to create a navmenu and it works a treat,
    however i also have
    > flash
    > on some of the pages, and the fireworks submenus don't
    seem to like
    > showing up
    > over the flash! see
    http://www.gammies.co.uk/construction.asp
    for what i
    > mean.
    > the nav links to construction, groundcare and
    recreational don't show
    > becuase
    > of the flash. I was trying to see if there was some
    option to send the
    > flash
    > to the back of the page as such so that the navmenu was
    on top but
    > couldn't get
    > it, and i'm no sure what i'd have to do code wise to
    change it (if it's a
    > code
    > issue). By the way it does it in both firefox and IE All
    help greatly
    > appreciated.. Thanks Chris
    >

  • I'm new to java and I need some quick help with NetBeans.

    Hi. To whomever can help here's the problem. I've been trying to install netbeans ide 5.0 on my computer for a while now and i can't seem to find out what is wrong. I'm in a java programming course and i need the J2SE Developement Kit 5.0 Update 7 and NetBeans IDE 5.0 Installer on my comp. Whenever i go to install it, it can't automatically create a directory and has erroe null in place of it. Whenever i made a new directory for it a page would come up telling me all of the errors during the installation which are null. Since i have administrator privelages and plenty of free space on my hardrive.

    Hi,
    I want to suggest you that
    1.please check if any prerequisite is require before installing the NetBeans IDE,i hope there is nothing like that except proper jdk on your machine.
    2.if you already having JDK on your machine check for the compatibility of that jdk version with the required NetBeans IDE version.
    3.follow the steps provided to install the NetBeans IDE 5.0 for that refer the below link
    http://www.netbeans.org/community/releases/50/install.html
    hope you will get rid of the problem .....
    ---Vidya

  • Quick Help With School Work

    I am current student that just got into a web design class, I was sent home with some homework seeing what we know and I have a question that I am stumped on .Was wondering if anyone could help me with this question:
    Write an advanced CSS selector that specifically targets the input type or name for the following HTML:
    <input type="text" name="address1" value=""/>
    Thank you very much from web student and indvidual wanting to learn from their peers

    Hi
    As john said it may not be what is required, but as the css attribute selector is css2.1, (and further expanded in css3) I would not expect this to be included in a curriculum at this time.
    CSS2.1 is only supported by the newer browsers and not IE versions < 7.
    But if you wish to be certain you could also include this in your answer see - http://www.w3schools.com/css/css_attribute_selectors.asp. For full reference you could also point your tutor to - http://www.w3.org/TR/css3-selectors/.
    PZ

  • Quick help with a new Safari user?

    Hey guys,
    Since Mountain Lion, Firefox was destroying my CPU and was sending the fans nuts! So Ive made the switch to Safari.
    2 really quick questions. I have imported my bookmarks but I HATE the way bookmarks work in Safari, or at least the only way in which I have found so far. So instead of having to open up the horrible bookmarks window with the page previews ala iTunes cover art, can I somehow get a Firefox like drop down bookmark list in the current window I have?
    Also I do not like having to tell Safari that i want to browse privately every time I use Safari. Can I set safari to never save my history?
    Thanks

    Ok I made myself a new folder called bookmarks that gives me drop down bookmarks like I wanted but can I get rid of the button that opens the bookmark window?
    Still not solved history issue.

  • Need Quick Help with Unordered List in Table (text too small)

    Hi,
    I have a table with 2 unordered lists and the font size is smaller than what I need.
    I'm using CSS and have checked all of my font sizes and I have all of what I consider my normal text set to 12.
    When my client views the page on his browser, the unordered lists appears to be about a size 8. I checked on my cell phone and I see what he's talking about.
    I set the <ul> and <li> to font size 12, but the problem still exists.
    It's almost like the table is scaling the text down.
    I worked all night trying to figure out what I've done wrong (newbie ) and I can't fix it and my client is waiting!
    Here's the page: http://www.precisioncleaning.com/expert_witness_services.html
    Please help!
    Thanks,
    Kathy

    I tried adding a new CSS rule to the table font, but it didn't work.
    I also edited the <tr> and <td> but still didn't work.
    I think something higher up is messing the table up. I don't know anything about specificity or how to see who has the power to overwrite the table.
    Do you?

  • Help with UPDATE statment

    Hello,
    i have a table like this:
    create table test
    (id number,
    stat number,
    id_num number);data in table:
    insert into table test (id,stat,id_num) values (1,112,'');
    insert into table test (id,stat,id_num) values (1,123,'');
    insert into table test (id,stat,id_num) values (2,134,'');
    insert into table test (id,stat,id_num) values (2,111,'');
    insert into table test (id,stat,id_num) values (3,112,'');
    insert into table test (id,stat,id_num) values (4,111,'');
    insert into table test (id,stat,id_num) values (4,12,'');
    insert into table test (id,stat,id_num) values (4,11,'');I want to update column id_num with sequence number under same ID.
    Below is the table with correctly updated coloumn.
    insert into table test (id,stat,id_num) values (1,112,1);
    insert into table test (id,stat,id_num) values (1,123,2);
    insert into table test (id,stat,id_num) values (2,134,1);
    insert into table test (id,stat,id_num) values (2,111,2);
    insert into table test (id,stat,id_num) values (3,112,1);
    insert into table test (id,stat,id_num) values (4,111,1);
    insert into table test (id,stat,id_num) values (4,12,2);
    insert into table test (id,stat,id_num) values (4,11,3);Can someone give me a hint how to pull this off?
    Thank you for your help!

    Hi,
    what is the order of assigning the sequence within the same id?
    You cannot rely on the order of row number as Oracle does not ensure that it is giving back the rows in the sequence in which they have been inserted.
    I have assumed here that within the id the id_num is numbered ordered by stat:
    MERGE INTO test a
         USING (SELECT id, stat
                     , ROW_NUMBER () OVER (PARTITION BY id ORDER BY stat) AS val
                  FROM test) b
            ON (a.id = b.id AND a.stat = b.stat)
    WHEN MATCHED
    THEN
       UPDATE SET id_num = val;
    SELECT *
      FROM test
    ORDER BY id, stat;
            ID       STAT     ID_NUM
             1        112          1
             1        123          2
             2        111          1
             2        134          2
             3        112          1
             4         11          1
             4         12          2
             4        111          3Regards.
    Al

  • Need some quick help with server proxy on PI 7.1 system

    Hi,
    I am implementing a server proxy on the PI 7.1 system to do some logging to a table. So, when I go the the proxy in sproxy and generate it, in the interface section on the properties tabs I only see a drop down that says point to point enabled. There is no implementing class to click into and thus not method to populate with the custom code. Some direction would be appreciated, I have been working 7.0 for a while, so the missing implementing class is new to me! I know the method name has changed from the execute_asycronous etc... Am I going to the wrong place now to find the implementing method?
    Thanks,
    Chris

    Whoops! Brain cramp. accidentally set the interface to outbound and not inbound in the ESR lol. Sorry.

  • Need some quick help with jbutton

    Hi,
    My first post so please be gentle!
    I currently have two buttons in my container. The first one when pressed calls another function that generates a set of coordinates (button = generate). I now have another button that wants to take those coordinates and draw them on-screen, but I'm having trouble doing this since I can't get the "generate" button function to pass the xycoords over to the "draw" button function. I'm more of a Fortran/Perl programmer and I'm a bit confused how to go about this. I tried making the variable (xycoords) a gloabl variable, but id rather not do this.
    Any tips?
    Cheers,
    Adriano

    Sure, show us the code. Otherwise we have to try to read you mind.
    Here is the scenario you are in:
    Event Driven Method (ActionPerformed/ButtonClicked/etc): you do not have arguments that you can control, so if you want to use something from within that method you have to have visibility to it (global definition with respect to the routine) and in the Java world that usually boils down to class variables or some type of public data class.
    Now, it you want the coordinates of the click event, that is contained in the MouseEvent... getX and getY, so you can use these as arguments to other methods from within your MouseListener.

  • Need a quick help with miniracer

    Miniracer does not run on 64 bit. I contacted upstream, and they say it should work on 32 bit, the error is connected with 64 bit. They asked me to confirm this, but I dont have a 32 bit archlinux near me. Could you please test the package on 32 bit please?
    Package: https://aur.archlinux.org/packages.php?ID=8702
    Last edited by SanskritFritz (2011-12-12 14:42:39)

    I try to start a race and it freezes. Not sure if that's the same issue you have?

  • Quick help with form mailer

    I just finished creating my form and .php file to mail it to an email address. All the input fields are working properly, except one. I can not get a drop down (Main Category) submission field to email me the submission. The form works fine on the website, the email leaves that one field blank. Any help in my coding would be greatly appreciated.
    form:
    <form action="merchantsignup.php" method="post" id="contact_form">
        <center><table width="637" border="0">
          <tr>
            <td>Business Name:
      <br />
        <input type="text" name="name" /></td>
            <td>Business Phone:
      <br />
        <input type="text" name="phone" /></td>
            <td>Business Email:
      <br />
        <input type="text" name="email" /></td>
          </tr>
          <tr>
            <td>Business Address:
      <br />
        <input type="text" name="address" /></td>
            <td>City & Zip:
      <br />
        <input type="text" name="city/zip" /></td>
            <td>Business Webpage:
      <br />
        <input type="text" name="webpage" /></td>
          </tr>
          <tr>
            <td>Main Category<br />
              <select name="Main Category">
              <option value="Food">Food</option>
        <option value="Soda">Soda</option>
              <option value="Candy">Candy</option>
              </select>
    </td>
            <td>Sub Category:
      <br />
        <input type="text" name="category2" /></td>
            <td><p> </p></td>
          </tr>
          <tr>
          </table>
            <td><p>About the Business: <br />
              <textarea cols="88" rows="8" name="about"></textarea>
    </h3>
            </p>
            <p><input type="submit" name="submit" value="Send" />
      <input type="reset" name="reset" value="Clear Form" /></p>
        </form>
    .php file
    <?php
    /* Email Variables */
    $emailSubject = 'Merchant Signup';
    $webMaster = '[email protected]';
    /* Data Variables */
    $name = $_POST['name'];
    $phone = $_POST['phone'];
    $email = $_POST['email'];
    $address = $_POST['address'];
    $city = $_POST['city/zip'];
    $webpage = $_POST['webpage'];
    $main_category = $_POST['main'];
    $category2 = $_POST['category2'];
    $about = $_POST['about'];
    $copy_photo[0]="";
    $body = <<<EOD
    <br><hr><br>
    Name: $name <br>
    Phone: $phone <br>
    Email: $email <br>
    Address: $address <br>
    City: $city <br>
    Wegpage: $webpage <br>
    Main Category: $Main <br>
    Category2: $category2 <br>
    About: $about <br>
    EOD;
    $headers = "From: $email\r\n";
    $headers .= "Content-type: text/html\r\n";
    $success = mail($webMaster, $emailSubject, $body,
    $headers);
    /* Results rendered as HTML */
    $theResults = <<<EOD
    <html>
    <head>
    <title>sent message</title>
    <meta http-equiv="refresh" content="3;URL=http://lf.com/index.shtml">
    <style type="text/css">
    <!--
    body {
    background-color: #000;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 20px;
    font-style: normal;
    line-height: normal;
    font-weight: normal;
    color: #FF0000;
    text-decoration: none;
    padding-top: 400px;
    margin-left: 250px;
    width: 800px;
    -->
    </style>
    </head>
    <div align="center"> Thank you for submitting your information! You will recieve an email from us shortly! </div>
    </div>
    </body>
    </html>
    EOD;
    echo "$theResults";
    ?>
    Any help would be greatly greatly appreciated!

    Your form doesn't match your script.  Try to be consistent in your naming conventions.  Also, PHP is cAsE sEnSiTiVe so you need to pay attention to that as well.
    Change this in your form:
    <select name="Main Category">
    to this:
    <select name="main_category">
    And change this data variable in PHP:
    $main_category = $_POST['main'];
    to this:
    $main_category = $_POST['main_category'];
    It should work now.
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists 
    http://alt-web.com/
    http://twitter.com/altweb
    http://alt-web.blogspot.com/

  • Quick help with boot camp parition

    ok well i had to uninstall the Boot Camp partition a few months ago due to some problems, now i want to put it back on BUT, when i click partition... after a little while this message pops up:
    The disk cannot be partitioned because some files cannot be moved.
    Back up the disk and use Disk Utility to format it as a single Mac OS Extended (Journaled) volume. Restore your information to the disk and try using Boot Camp Assistant again.
    i did repartition this hard drive but i keep getting that message. if you could plz help me...anyone...

    Since the time that you restored your disk to a single partition and now, Mac OS files have scattered across your hard drive making it impossible to repartition.
    Some suggestions:
    • Search these forums for suggestions given to all those who have posted this question before.
    • Try a smaller partition, if your desired Windows use permits. It's possible that the scattering of your Mac OS files does not extend across the entire hard drive.
    • Buy a program which will defragment your hard drive, and run it.
    • Clone your hard drive (or make a Time Machine backup), then reformat and restore, as per the error message.

Maybe you are looking for

  • Hp psc 1350 won't scan

    My hp psc 1350 all in one will not scan.  I have windows Vista 32 bit.  I tried for hours looking on here.  i can't scan from the scan button or the other ways some posts said to go to windows photo gallery and even paint.   On windows photo gallery

  • Career in Oracle Apps ? Please Help

    Hello Everyone There is a question which is troubling me a lot, I will be very happy if I can get any valuable feedback on it. Let me describe my self, I am a software Engg with a work exp of 3.5 yrs in PL/SQL (Banking Domain) and currently I have sw

  • ORA-22285

    HI, I am having a problem in pl/sql. I am creating a directory object as----"create or replace directory photo_folder as 'D:\IMAGE'; Then i have made a table like this----create table test(id varchar2(10),image bfile); After that when i am trying to

  • Question about XSL Mapper in BPEL designer

    Hi, I have a question regarding the XSL mapper within JDeveloper BPEL Designer. Scenario: Consider 1. Source xsd with 3 attributes 2. Target xsd with 5 attributes An XSL mapping is defined for 3 source attributes to the corresponding target attribute

  • Timestamp getting lost

    All: After executing an interface, the date fields are losing its time stamp. I have checked the C$ table and the I$ table for possible mismatch between the datatypes. But the fields are of Date type (as expected and desired). Any suggestions on what