Cannot get the hosts file to operate or change.

I have tried to every way I could find on the internet to change the hosts file on my Mac OS X 10.4.11 computer plus several newer macs that operate in my office. I was able to easily do it on the PC's but not on the Macs. I modified the /etc hosts file directly to no avail, modified it using the terminal commands and also tried using the NetInfo manager. I am NOT a tech guy, just a guy trying to get his computers to work properly. A tech company just changed our router to a Cisco ASA device which is why this change needs to be made, they did not know how to make the changes to the hosts files on a Mac. Everybody in the office loves our Macs so to not be able to get to our own website and webmail is frustrating. Here is what I changed the hosts file to:
# Host Database
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
127.0.0.1 localhost
192.168.16.2 auctionbid.stoutauctions.com
192.168.16.3 mail.stoutauctions.com
192.168.16.3 smtp.stoutauctions.com
192.168.16.4 stoutauctions.com
255.255.255.255 broadcasthost
::1 localhost
Is something else in the system I need to change to make this take effect? Is something set wrong? Any help would be greatly appreciated.
Also if anyone knows of a reputable company that will do remote work on Macs, please let me know. I have a few things that I don't know how to do and would not be worth a trip to the middle of nowhere for a tech company so if they can do it remotely that would be great.
Thanks!
Greg

Hmmm, the line after...
127.0.0.1 localhost
Should be...
255.255.255.255 broadcasthost
Not sure if that is it or not.
Did you see this article, especially for adding from a hosts.txt file?
http://support.apple.com/kb/TA27291?viewlocale=en_US
Did you flush the DNS Cache after changes?
How to Flush DNS in Mac OSX using Terminal...
In Mac OSX Leopard, you can use the command dnscacheutil -flushcache to flush the DNS resolver cache:
dnscacheutil -flushcache
In Mac OSX versions 10.5.1 and before, the command lookupd -flushcache performed the same task:
lookupd -flushcache

Similar Messages

  • Recently purchased song and another I transfered into my ITunes library vannot be set up in a playlist.I get the message"file cannot be located".Originally I could listen to the purchased song but now that will no longer play.What do I need to do to ?

    Recently purchased a song from ITunes and another that I downloaded from a CD will not transfer to a playlist and will not even allow me to listen to the songs.I get the message "file cannot be located"What can I do to get my system to locate the file?Originally I could play the songs from my desktop and I was able to transfer to my IPad.

    Because the location for each song in your library is on your hard drive.  If the hard drive isn't there, how can iTunes play it?
    You'll have to move/copy the music from your hard drive to your computer's hard drive.
    Basically, EASIEST way to do all this, if you don't care about your play counts, etc...
    -Delete EVERYTHING from iTunes, so that your library is now empty.
    -Go to "Advanced" inside of the "Preferences" window, found in the "Edit" drop-down.  You can also access Preferences by pressing Ctrl+, (Press Ctrl and the comma key)
    -Change your iTunes Media Folder Location to something simple, but on your computer. I use C:/iTunes.  Make sure "Keep iTunes Media Folder Organized" and "Copy files to...." are both checked.  You can close Preferences now.
    -Now, drag and drop your music from your hard drive into your iTunes library.  iTunes will automatically add the music to your library, as you would expect, and also creates a copy of each file to place into that iTunes Media Folder you just created.
    Shouldn't have any more problems...

  • My Photoshop Elements does not start any more. It gives response "Photoshop elements cannot start or continue because of missing file(s). Please reinstall." How do I get the installing file again (I bought it via internet the first time december 2013?)

    My Photoshop Elements does not start any more. It gives response "Photoshop elements cannot start or continue because of missing file(s). Please reinstall." How do I get the installing file again (I bought it from Adobe via internet the first time december 2013?)

    Did you download the Basic/Free version?
    I also thought the Trial period was as long as you needed!?
    What is your Warranty and Return Policy?
    You get to use VueScan for as long as you want before you buy it, so we recommend you test it before you buy it to make sure it meets your needs.
    All sales are final and there are no refunds.
    Isn't this a bit harsh? Naah I actually prefer to solve problems, and if I offer refunds, people give up too easily. If I can't solve your problem after you send a few Problem Reports (see above), I'm happy to give a refund.
    http://www.hamrick.com/sup.html#q

  • Cannot get the past dialogue box to open in illustrator since upgrading to Yosemite. Click it but nothing happens. Also File Open works intermittently. Is this a finder preference issue?

    Cannot get the past dialogue box to open in illustrator since upgrading to Yosemite. Click it but nothing happens. Also File Open works intermittently. Is this a finder preference issue?

    one of those days --- it's the PLACE dialogue box

  • I am using the trial version of CC and cannot get the auto blend layers working despite following many videos on youtube etc. I have selected all layers but no matter which order I select etc all I get is an output of the first file in the stack - help!!

    I am using the trial version of CC and cannot get the auto blend layers working despite following many videos on youtube etc. I have selected all layers but no matter which order I select etc all I get is an output of the first file in the stack - help!!

    <moved from Adobe Creative Cloud to Photoshop General Discussion>

  • HT201210 I have done all of the things on this list, to include editing the hosts file with no the same error each time (3194).  I am trying to restore my iphone 4 ios 6 to get it unlocked.  Diagnostics show no issue communicating with apple. Help.

    I am trying to restore my iphone 4 ios 6 to acheive unlock.  hit restore and it unloads software, confirms with apple then displays the 3194 error.  I have turned off my virus scanner, unplugged all usb except for iphone, edited the hosts file and run diagnostics which showes communication with apple is fine.  What do I need to do to get my ipone to restore?

    There is nothing wrong with the OS update.
    Delete ALL your email accounts.
    Restart Playbook
    Put the accounts back and ensure they are all set with PUSH ON.  Manual (push off) will burn battery.
    Similarly delete your wifi connections and add back when required. 
    Turn off wifi is not connected to wifi. 
    Any "hunting for connection" in email or wifi will burn up battery.

  • I cannot get a photo file off my iphone no matter what i try,even when the photo total pops up as 41 there are 344 on the phone

    I have an iphone 3 that was synced awhile back.All was fine,now I need space on the phone & cannot get a picture file with 344 photos off the phone. I've tried not checking any folders to sync

    Email it to yourself, then save the file and then see if you can convert it to MP3.

  • When going through the download process with social monkee and getting to the point of adding it to firefox I get the following message: 'Social Monkee could not be installed because firefox cannot modify the needed file'. How can this be fixed?

    When going through the download process with social monkee and getting to the point of adding it to firefox I get the following message: 'Social Monkee could not be installed because firefox cannot modify the needed file'. How can this be fixed?

    That is usually caused by a missing unpack directive (&lt;em:unpack&gt;true&lt;/em:unpack&gt;) in the file install.rdf of that extension.
    See https://developer.mozilla.org/En/Updating_extensions_for_Firefox_4.0#XPI_unpacking
    -----

  • Firefox cannot modify the needed file. I get this message when I try to add a theme. I am using Linux Mint 14.

    I am currently using Linux Mint 14 with Firefox 21. I am trying to add new themes and add ons, but I keep getting the message "firefox cannot modify the needed file in linux". How can I correct this?
    Thanks

    Click the Firefox button at the top left, then click the ''Help'' menu and select ''Troubleshooting Information'' from the submenu. If you don't have a Firefox button, click the Help menu at the top and select ''Troubleshooting Information'' from the menu. Go to Open Profile Directory (or something similar) and delete a file named user.js

  • HT5148 I have a mpg file and when i open it in final cut I cannot get the sound only picture

    I have a mpg file and when i open it in final cut I cannot get the sound only picture

    MPEG means a whole bunch of different formats. What are the exact specs of your media? MPEG files often have multiplexed audio. You will probaby have to convert this.

  • I cannot get the file "Photoshop_13_LS16.7z" for Photoshop CS6, Photoshop CS6 Extended English to download; the url goes to an ascii file on screen.

    I cannot get the file "Photoshop_13_LS16.7z" for Photoshop CS6, Photoshop CS6 Extended English to download; the url goes to an ascii file on screen.  It's at Download CS6 products.  Can you help?

    use a different browser.
    you can also try dl'g from prodesigntools.com
    if you follow all 7 steps you can directly download a trial here:  Download CS6 products
    and activate with your serial number.
    if you have a problem starting the download, you didn't follow all 7 steps, or your browser does not accept cookies. 
    the most common problem is caused by failing to meticulously follow steps 1,2 and/or 3 (which adds a cookie to your system enabling you to download the correct version from adobe.com). 
    failure to obtain that cookie results in an error page being displayed after clicking a link on prodesigntools.com or initiates the download of an incorrect (eg, current) version.

  • I have imported a jpeg photo into iPhoto and cannot get the Places map to let me fix a position on the map. It remains disabled for my photo. Checking out the Help file has not given any solution.

    I have imported a jpeg photo into iPhoto  and cannot get the Places map tp show. I have tried the Help file and the information was not helpful. Can anyone give advice here?

    I am using iPhoto 9.1.1. When I select thephoto, then Places I get the window (Places to lookup disabled). When I hit theInfo button I get the size an JPEG notification, and  Faces and Key words. The “reverse” of thepicture shows a window with Rotate, Hide, Trash etc.
    When I select Places, get the Google worldmap, and this case a pin on Sydney Australia showing that eighteen photos arecorrectly placed. I am unable to make the connection to San Francisco wherethis particular photo was taken on a very modern camera.
    Regards,
    Theogt

  • I have requested and accepted the most current Firefox program updates with my windows vista system. They are not registering but I am told they are downloaded. Then I cannot get the printer option to work with any version of firefox. in English

    I have taken the firefox updates when offered to 4.4. I have the browser as an aside to Internet Explorer 9 as a backup browser. When I use Firefox I am being told my system is not up to date and I need a newer version. I download the version and keep getting told I am not current with firefox. When Firefox DOES work I cannot get any printer icon or settings to enable and allow the printing of a page. I have to use IE9 to get the printer to work. Using eBay I cannot get the uploading of pictures from my computer to consistently operate even though I use small JPG files under 500KB.

    There are a lot of IntelliTXT like ''ad'' pop-ups possible.
    If your current Adblock Plus filter settings aren't blocking some pop-ups then it is best to take this to the Adblock Plus forum.
    * https://adblockplus.org/forum/
    * http://en.wikipedia.org/wiki/Category:Internet_advertising_services_and_affiliate_networks
    * http://en.wikipedia.org/wiki/IntelliTXT

  • Error Message "the system cannot find the specified file"

    Hi,
    I built my website with iWeb, but when I want to publish it on my own domain (not .mac) I've always this error message (the system cannot find the specified file) with many files. I've tryed many ftp host but I still have the same problem. I ask my host domain manager and everything is ok with them. Si I guess that the problem comes from iWeb.
    Please help me.
    Thanks

    I get the error: Cannot Copy 08 the curse in on my house: Cannot find the specified file. Make sure you specify the correct path and file name.
    The song "the curse in on..." is on the "into the woods" soundtrack. I deleted the entire soundtrack from my iTunes Library, shut down and tried again. Same error. I did a search of all three hd (2 external and c) nothing found. I searched for song name and "into the woods" I even searched for the artist "Nicholas Parson Company" nothing on any of the 3 HDs. I also went into explorer and manually searched for the song under soundtracks, misc, various and I could not find it. I consolidated my library and restarted. I tried again and same error message. Can a level 4 or 5 offer any help. I am at a loss...
    The error won't let me copy one library to another HD.

  • NullPointerException - Cannot get the value from variable f_cashGiven

    In SubCheckout.java (a POS), what I want is when Payment button (f_cashPayment) is pressed, the action "Cash" is performed, get the value from Cash Given (f_cashGiven), do the subtraction and post the value as Cash Return (f_cashReturn). The code is filled in actionPerformed. But I cannot get the value by using f_cashGiven.getValue() from VNumber class. It returns NULL. This should be quite straight forward, but I do not know what is wrong. Please help!
    Enclosed please find the source code of SubCheckout.java and VNumber.java
    This is the code of SubCheckout.java :
    * The contents of this file are subject to the   Compiere License  Version 1.1
    * ("License"); You may not use this file except in compliance with the License
    * You may obtain a copy of the License at http://www.compiere.org/license.html
    * Software distributed under the License is distributed on an  "AS IS"  basis,
    * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
    * the specific language governing rights and limitations under the License.
    * The Original Code is Compiere ERP & CRM Smart Business Solution. The Initial
    * Developer of the Original Code is Jorg Janke. Portions created by Jorg Janke
    * are Copyright (C) 1999-2005 Jorg Janke.
    * All parts are Copyright (C) 1999-2005 ComPiere, Inc.  All Rights Reserved.
    * Contributor(s): ______________________________________.
    package org.compiere.pos;
    import java.awt.*;
    import java.awt.event.*;
    import java.math.BigDecimal;
    import javax.swing.border.*;
    import org.compiere.grid.ed.*;
    import org.compiere.swing.*;
    import org.compiere.util.*;
    *     POS Checkout Sub Panel
    *  @author Jorg Janke
    *  @version $Id: SubCheckout.java,v 1.3 2005/03/11 20:28:22 jjanke Exp $
    public class SubCheckout extends PosSubPanel implements ActionListener
          *      Constructor
          *     @param posPanel POS Panel
         public SubCheckout (PosPanel posPanel)
              super (posPanel);
         }     //     PosSubCheckout
         private CButton f_register = null;
         private CButton f_summary = null;
         private CButton f_process = null;
         private CButton f_print = null;
         private CLabel f_lcreditCardNumber = null;
         private CTextField f_creditCardNumber = null;
         private CLabel f_lcreditCardExp = null;
         private CTextField f_creditCardExp = null;
         private CLabel f_lcreditCardVV = null;
         private CTextField f_creditCardVV = null;
         private CButton f_cashPayment = null;
         private CLabel f_lcashGiven = null;
         private VNumber f_cashGiven = null;
         private CLabel f_lcashReturn = null;
         private VNumber f_cashReturn = null;
         private CButton f_creditPayment = null;
         /**     Logger               */
         private static CLogger log = CLogger.getCLogger(SubCheckout.class);
          *      Initialize
         public void init()
              //     Title
              TitledBorder border = new TitledBorder(Msg.getMsg(Env.getCtx(), "Checkout"));
              setBorder(border);
              //     Content
              setLayout(new GridBagLayout());
              GridBagConstraints gbc = new GridBagConstraints();
              gbc.insets = INSETS2;
              //     --     0
              gbc.gridx = 0;
              f_register = createButtonAction("Register", null);
              gbc.gridy = 0;
              add (f_register, gbc);
              f_summary = createButtonAction("Summary", null);
              gbc.gridy = 1;
              add (f_summary, gbc);
              f_process = createButtonAction("Process", null);
              gbc.gridy = 2;
              add (f_process, gbc);
              f_print = createButtonAction("Print", null);
              gbc.gridy = 3;
              add (f_print, gbc);
              //     --     1 -- Cash
              gbc.gridx = 1;
              gbc.gridheight = 2;
              gbc.fill = GridBagConstraints.BOTH;
              gbc.weightx = .1;
              CPanel cash = new CPanel(new GridBagLayout());
              cash.setBorder(new TitledBorder(Msg.getMsg(Env.getCtx(), "Cash")));
              gbc.gridy = 0;
              add (cash, gbc);
              GridBagConstraints gbc0 = new GridBagConstraints();
              gbc0.insets = INSETS2;
              gbc0.anchor = GridBagConstraints.WEST;
              f_lcashGiven = new CLabel(Msg.getMsg(Env.getCtx(),"CashGiven"));
              cash.add (f_lcashGiven, gbc0);
              f_cashGiven = new VNumber("CashGiven", false, false, true, DisplayType.Amount,
                   Msg.translate(Env.getCtx(), "CashGiven"));
              f_cashGiven.addActionListener(this);
              f_cashGiven.setColumns(10, 25);
              cash.add (f_cashGiven, gbc0);
              f_cashGiven.setValue(Env.ZERO);
              f_lcashReturn = new CLabel(Msg.getMsg(Env.getCtx(),"CashReturn"));
              cash.add (f_lcashReturn, gbc0);
              f_cashReturn = new VNumber("CashReturn", false, true, false, DisplayType.Amount,
                   "CashReturn");
              f_cashReturn.setColumns(10, 25);
              cash.add (f_cashReturn, gbc0);
              f_cashReturn.setValue(Env.ZERO);
              f_cashPayment = createButtonAction("Payment", null);
              f_cashPayment.setActionCommand("Cash");
              gbc0.anchor = GridBagConstraints.EAST;
              gbc0.weightx = 0.1;
              cash.add (f_cashPayment, gbc0);
              //     --     1 -- Creditcard
              CPanel creditcard = new CPanel(new GridBagLayout());
              creditcard.setBorder(new TitledBorder(Msg.translate(Env.getCtx(), "CreditCardType")));
              gbc.gridy = 2;
              add (creditcard, gbc);
              GridBagConstraints gbc1 = new GridBagConstraints();
              gbc1.insets = INSETS2;
              gbc1.anchor = GridBagConstraints.WEST;
              gbc1.gridx = 0;
              gbc1.gridy = 0;
              f_lcreditCardNumber = new CLabel(Msg.translate(Env.getCtx(), "CreditCardNumber"));
              creditcard.add (f_lcreditCardNumber, gbc1);
              gbc1.gridy = 1;
              f_creditCardNumber = new CTextField(18);
              creditcard.add (f_creditCardNumber, gbc1);
              gbc1.gridx = 1;
              gbc1.gridy = 0;
              f_lcreditCardExp = new CLabel(Msg.translate(Env.getCtx(),"CreditCardExp"));
              creditcard.add (f_lcreditCardExp, gbc1);
              gbc1.gridy = 1;
              f_creditCardExp = new CTextField(5);
              creditcard.add (f_creditCardExp, gbc1);
              gbc1.gridx = 2;
              gbc1.gridy = 0;
              f_lcreditCardVV = new CLabel(Msg.translate(Env.getCtx(), "CreditCardVV"));
              creditcard.add (f_lcreditCardVV, gbc1);
              gbc1.gridy = 1;
              f_creditCardVV = new CTextField(5);
              creditcard.add (f_creditCardVV, gbc1);
              gbc1.gridx = 3;
              gbc1.gridy = 0;
              gbc1.gridheight = 2;
              f_creditPayment = createButtonAction("Payment", null);
              f_creditPayment.setActionCommand("CreditCard");
              gbc1.anchor = GridBagConstraints.EAST;
              gbc1.weightx = 0.1;
              creditcard.add (f_creditPayment, gbc1);
         }     //     init
          *      Get Panel Position
         public GridBagConstraints getGridBagConstraints()
              GridBagConstraints gbc = super.getGridBagConstraints();
              gbc.gridx = 0;
              gbc.gridy = 3;
              return gbc;
         }     //     getGridBagConstraints
          *      Dispose - Free Resources
         public void dispose()
              super.dispose();
         }     //     dispose
          *      Action Listener
          *     @param e event
         public void actionPerformed (ActionEvent e)
              String action = e.getActionCommand();
              if (action == null || action.length() == 0)
                   return;
              log.info( "PosSubCheckout - actionPerformed: " + action);
              if (e.getSource() == f_cashGiven) {
                   f_cashGiven.setValue(f_cashGiven.getValue());
                   System.out.println("f_cashGiven"+f_cashGiven.getDisplay());
              //     Register
              //     Summary
              //     Print
              if (action.equals("Cash")) {
                   BigDecimal CashGiven, GrandTotal, CashReturn;
                   System.out.println("Cash given is "+f_cashGiven.getDisplay());
                   CashGiven = (BigDecimal)f_cashGiven.getValue();
                   GrandTotal = (BigDecimal)p_posPanel.f_curLine.getOrder().getGrandTotal();
                   CashReturn = CashGiven.subtract(GrandTotal);
                   f_cashReturn.setValue(CashReturn);
              //     Cash (Payment)
              //     CreditCard (Payment)
         }     //     actionPerformed
    }     //     PosSubCheckoutThis is the code of VNumber.java :
    * The contents of this file are subject to the   Compiere License  Version 1.1
    * ("License"); You may not use this file except in compliance with the License
    * You may obtain a copy of the License at http://www.compiere.org/license.html
    * Software distributed under the License is distributed on an  "AS IS"  basis,
    * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
    * the specific language governing rights and limitations under the License.
    * The Original Code is Compiere ERP & CRM Smart Business Solution. The Initial
    * Developer of the Original Code is Jorg Janke. Portions created by Jorg Janke
    * are Copyright (C) 1999-2005 Jorg Janke.
    * All parts are Copyright (C) 1999-2005 ComPiere, Inc.  All Rights Reserved.
    * Contributor(s): ______________________________________.
    package org.compiere.grid.ed;
    import java.awt.*;
    import java.awt.event.*;
    import java.beans.*;
    import java.math.*;
    import java.text.*;
    import java.util.logging.*;
    import javax.swing.*;
    import javax.swing.text.*;
    import org.compiere.apps.*;
    import org.compiere.model.*;
    import org.compiere.swing.*;
    import org.compiere.util.*;
    *     Number Control
    *      @author      Jorg Janke
    *      @version      $Id: VNumber.java,v 1.41 2005/09/03 01:57:16 jjanke Exp $
    public final class VNumber extends JComponent
         implements VEditor, ActionListener, KeyListener, FocusListener
         /**     Number of Columns (12)          */
         public final static int SIZE = 12;
          *  IDE Bean Constructor
         public VNumber()
              this("Number", false, false, true, DisplayType.Number, "Number");
         }   //  VNumber
          *     Create right aligned Number field.
          *     no popup, if WindowNo == 0 (for IDs)
          *  @param columnName column name
          *  @param mandatory mandatory
          *  @param isReadOnly read only
          *  @param isUpdateable updateable
          *  @param displayType display type
          *  @param title title
         public VNumber(String columnName, boolean mandatory, boolean isReadOnly, boolean isUpdateable,
              int displayType, String title)
              super();
              super.setName(columnName);
              m_columnName = columnName;
              m_title = title;
              setDisplayType(displayType);
              LookAndFeel.installBorder(this, "TextField.border");
              this.setLayout(new BorderLayout());
    //          this.setPreferredSize(m_text.getPreferredSize());          //     causes r/o to be the same length
    //          int height = m_text.getPreferredSize().height;
    //          setMinimumSize(new Dimension (30,height));
              //     ***     Text     ***
              m_text.setBorder(null);
              m_text.setHorizontalAlignment(JTextField.TRAILING);
              m_text.addKeyListener(this);
              m_text.addFocusListener(this);
              //     Background
              setMandatory(mandatory);
              this.add(m_text, BorderLayout.CENTER);
              //     ***     Button     ***
              m_button.setIcon(Env.getImageIcon("Calculator10.gif"));
              m_button.setMargin(new Insets(0, 0, 0, 0));
              m_button.setFocusable(false);
              m_button.addActionListener(this);
              this.add (m_button, BorderLayout.EAST);
              //     Prefereed Size
              this.setPreferredSize(this.getPreferredSize());          //     causes r/o to be the same length
              //  Size
              setColumns(SIZE, CComboBox.FIELD_HIGHT-4);     
              //     ReadWrite
              if (isReadOnly || !isUpdateable)
                   setReadWrite(false);
              else
                   setReadWrite(true);
         }     //     VNumber
          *  Dispose
         public void dispose()
              m_text = null;
              m_button = null;
              m_mField = null;
         }   //  dispose
          *     Set Document
          *  @param doc document
         protected void setDocument(Document doc)
              m_text.setDocument(doc);
         }     //     getDocument
         private String               m_columnName;
         protected int               m_displayType;     //  Currency / UoM via Context
         private DecimalFormat     m_format;
         private String               m_title;
         private boolean               m_setting;
         private String               m_oldText;
         private String               m_initialText;
         private boolean               m_rangeSet = false;
         private Double               m_minValue;
         private Double               m_maxValue;
         private boolean               m_modified = false;
         /**  The Field                  */
         private CTextField          m_text = new CTextField(SIZE);     //     Standard
         /** The Button                  */
         private CButton              m_button = new CButton();
         private MField          m_mField = null;
         /**     Logger               */
         private static CLogger log = CLogger.getCLogger(VNumber.class);
          *      Set no of Columns
          *     @param columns columns
         public void setColumns (int columns, int height)
              m_text.setPreferredSize(null);
              m_text.setColumns(columns);
              Dimension size = m_text.getPreferredSize();
              if (height > size.height)               //     default 16
                   size.height = height;
              if (CComboBox.FIELD_HIGHT-4 > size.height)
                   size.height = VLookup.FIELD_HIGHT-4;
              this.setPreferredSize(size);          //     causes r/o to be the same length
              this.setMinimumSize(new Dimension (columns*10, size.height));
              m_button.setPreferredSize(new Dimension(size.height, size.height));
         }     //     setColumns
          *     Set Range with min & max
          *  @param minValue min value
          *  @param maxValue max value
          *     @return true, if accepted
         public boolean setRange(Double minValue, Double maxValue)
              m_rangeSet = true;
              m_minValue = minValue;
              m_maxValue = maxValue;
              return m_rangeSet;
         }     //     setRange
          *     Set Range with min & max = parse US style number w/o Gouping
          *  @param minValue min value
          *  @param maxValue max value
          *  @return true if accepted
         public boolean setRange(String minValue, String maxValue)
              if (minValue == null || maxValue == null)
                   return false;
              try
                   m_minValue = Double.valueOf(minValue);
                   m_maxValue = Double.valueOf(maxValue);
              catch (NumberFormatException nfe)
                   return false;
              m_rangeSet = true;
              return m_rangeSet;
         }     //     setRange
          *  Set and check DisplayType
          *  @param displayType display type
         public void setDisplayType (int displayType)
              m_displayType = displayType;
              if (!DisplayType.isNumeric(displayType))
                   m_displayType = DisplayType.Number;
              m_format = DisplayType.getNumberFormat(displayType);
              m_text.setDocument (new MDocNumber(displayType, m_format, m_text, m_title));
         }   //  setDisplayType
          *     Set ReadWrite
          *  @param value value
         public void setReadWrite (boolean value)
              if (m_text.isReadWrite() != value)
                   m_text.setReadWrite(value);
              if (m_button.isReadWrite() != value)
                   m_button.setReadWrite(value);
              //     Don't show button if not ReadWrite
              if (m_button.isVisible() != value)
                   m_button.setVisible(value);
         }     //     setReadWrite
          *     IsReadWrite
          *  @return true if rw
         public boolean isReadWrite()
              return m_text.isReadWrite();
         }     //     isReadWrite
          *     Set Mandatory (and back bolor)
          *  @param mandatory mandatory
         public void setMandatory (boolean mandatory)
              m_text.setMandatory(mandatory);
         }     //     setMandatory
          *     Is it mandatory
          *  @return true if mandatory
         public boolean isMandatory()
              return m_text.isMandatory();
         }     //     isMandatory
          *     Set Background
          *  @param color color
         public void setBackground(Color color)
              m_text.setBackground(color);
         }     //     setBackground
          *     Set Background
          *  @param error error
         public void setBackground (boolean error)
              m_text.setBackground(error);
         }     //     setBackground
          *  Set Foreground
          *  @param fg foreground
         public void setForeground(Color fg)
              m_text.setForeground(fg);
         }   //  setForeground
          *     Set Editor to value
          *  @param value value
         public void setValue(Object value)
              log.finest("Value=" + value);
              if (value == null)
                   m_oldText = "";
              else
                   m_oldText = m_format.format(value);
              //     only set when not updated here
              if (m_setting)
                   return;
              m_text.setText (m_oldText);
              m_initialText = m_oldText;
              m_modified = false;
         }     //     setValue
          *  Property Change Listener
          *  @param evt event
         public void propertyChange (PropertyChangeEvent evt)
              if (evt.getPropertyName().equals(org.compiere.model.MField.PROPERTY))
                   setValue(evt.getNewValue());
         }   //  propertyChange
          *     Return Editor value
          *  @return value value (big decimal or integer)
         public Object getValue()
              if (m_text == null || m_text.getText() == null || m_text.getText().length() == 0)
                   return null;
              String value = m_text.getText();
              //     return 0 if text deleted
              if (value == null || value.length() == 0)
                   if (!m_modified)
                        return null;
                   if (m_displayType == DisplayType.Integer)
                        return new Integer(0);
                   return Env.ZERO;
              if (value.equals(".") || value.equals(",") || value.equals("-"))
                   value = "0";
              try
                   Number number = m_format.parse(value);
                   value = number.toString();      //     converts it to US w/o thousands
                   BigDecimal bd = new BigDecimal(value);
                   if (m_displayType == DisplayType.Integer)
                        return new Integer(bd.intValue());
                   if (bd.signum() == 0)
                        return bd;
                   return bd.setScale(m_format.getMaximumFractionDigits(), BigDecimal.ROUND_HALF_UP);
              catch (Exception e)
                   log.log(Level.SEVERE, "Value=" + value, e);
              if (m_displayType == DisplayType.Integer)
                   return new Integer(0);
              return Env.ZERO;
         }     //     getValue
          *  Return Display Value
          *  @return value
         public String getDisplay()
              return m_text.getText();
         }   //  getDisplay
          *      Get Title
          *     @return title
         public String getTitle()
              return m_title;
         }     //     getTitle
          *      Plus - add one.
          *      Also sets Value
          *     @return new value
         public Object plus()
              Object value = getValue();
              if (value == null)
                   if (m_displayType == DisplayType.Integer)
                        value = new Integer(0);
                   else
                        value = Env.ZERO;
              //     Add
              if (value instanceof BigDecimal)
                   value = ((BigDecimal)value).add(Env.ONE);
              else
                   value = new Integer(((Integer)value).intValue() + 1);
              setValue(value);
              return value;
         }     //     plus
          *      Minus - subtract one, but not below minimum.
          *      Also sets Value
          *     @param minimum minimum
          *     @return new value
         public Object minus (int minimum)
              Object value = getValue();
              if (value == null)
                   if (m_displayType == DisplayType.Integer)
                        value = new Integer(minimum);
                   else
                        value = new BigDecimal(minimum);
                   setValue(value);
                   return value;
              //     Subtract
              if (value instanceof BigDecimal)
                   BigDecimal bd = ((BigDecimal)value).subtract(Env.ONE);
                   BigDecimal min = new BigDecimal(minimum);
                   if (bd.compareTo(min) < 0)
                        value = min;
                   else
                        value = bd;
              else
                   int i = ((Integer)value).intValue();
                   i--;
                   if (i < minimum)
                        i = minimum;
                   value = new Integer(i);
              setValue(value);
              return value;
         }     //     minus
          *     Action Listener
          *  @param e event
         public void actionPerformed (ActionEvent e)
              log.config(e.getActionCommand());
              if (ValuePreference.NAME.equals(e.getActionCommand()))
                   if (MRole.getDefault().isShowPreference())
                        ValuePreference.start (m_mField, getValue());
                   return;
              if (e.getSource() == m_button)
                   m_button.setEnabled(false);
                   String str = startCalculator(this, m_text.getText(), m_format, m_displayType, m_title);
                   m_text.setText(str);
                   m_button.setEnabled(true);
                   try
                        fireVetoableChange (m_columnName, m_oldText, getValue());
                   catch (PropertyVetoException pve)     {}
                   m_text.requestFocus();
         }     //     actionPerformed
          *     Key Listener Interface
          *  @param e event
         public void keyTyped(KeyEvent e)    {}
         public void keyPressed(KeyEvent e)  {}
          *     Key Listener.
          *          - Escape           - Restore old Text
          *          - firstChange     - signal change
          *  @param e event
         public void keyReleased(KeyEvent e)
              log.finest("Key=" + e.getKeyCode() + " - " + e.getKeyChar()
                           + " -> " + m_text.getText());
              //  ESC
              if (e.getKeyCode() == KeyEvent.VK_ESCAPE)
                   m_text.setText(m_initialText);
              m_modified = true;
              m_setting = true;
              try
                   if (e.getKeyCode() == KeyEvent.VK_ENTER)     //     10
                        fireVetoableChange (m_columnName, m_oldText, getValue());
                        fireActionPerformed();
                   else     //     indicate change
                        fireVetoableChange (m_columnName, m_oldText, null);     
              catch (PropertyVetoException pve)     {}
              m_setting = false;
         }     //     keyReleased
          *     Focus Gained
          *  @param e event
         public void focusGained (FocusEvent e)
              if (m_text != null)
                   m_text.selectAll();
         }     //     focusGained
          *     Data Binding to MTable (via GridController.vetoableChange).
          *  @param e event
         public void focusLost (FocusEvent e)
         //          log.finest(e.toString());
              //     APanel - Escape
              if (e.getOppositeComponent() instanceof AGlassPane)
                   m_text.setText(m_initialText);
                   return;
              try
                   fireVetoableChange (m_columnName, m_initialText, getValue());
                   fireActionPerformed();
              catch (PropertyVetoException pve)     {}
         }   //  focusLost
          *     Invalid Entry - Start Calculator
          *  @param jc parent
          *  @param value value
          *  @param format format
          *  @param displayType display type
          *  @param title title
          *  @return value
         public static String startCalculator(Container jc, String value,
              DecimalFormat format, int displayType, String title)
              log.config("Value=" + value);
              BigDecimal startValue = new BigDecimal(0.0);
              try
                   if (value != null && value.length() > 0)
                        Number number = format.parse(value);
                        startValue = new BigDecimal (number.toString());
              catch (ParseException pe)
                   log.info("InvalidEntry - " + pe.getMessage());
              //     Find frame
              Frame frame = Env.getFrame(jc);
              //     Actual Call
              Calculator calc = new Calculator(frame, title,
                   displayType, format, startValue);
              AEnv.showCenterWindow(frame, calc);
              BigDecimal result = calc.getNumber();
              log.config( "Result=" + result);
              calc = null;
              if (result != null)
                   return format.format(result);
              else
                   return value;          //     original value
         }     //     startCalculator
          *  Set Field/WindowNo for ValuePreference
          *  @param mField field
         public void setField (MField mField)
              m_mField = mField;
              if (m_mField != null
                   && MRole.getDefault().isShowPreference())
                   ValuePreference.addMenu (this, popupMenu);
         }   //  setField
          *      Remove Action Listner
          *      @param l Action Listener
         public void removeActionListener(ActionListener l)
              listenerList.remove(ActionListener.class, l);
         }     //     removeActionListener
          *      Add Action Listner
          *      @param l Action Listener
         public void addActionListener(ActionListener l)
              listenerList.add(ActionListener.class, l);
         }     //     addActionListener
          *      Fire Action Event to listeners
         protected void fireActionPerformed()
              int modifiers = 0;
              AWTEvent currentEvent = EventQueue.getCurrentEvent();
              if (currentEvent instanceof InputEvent)
                   modifiers = ((InputEvent)currentEvent).getModifiers();
              else if (currentEvent instanceof ActionEvent)
                   modifiers = ((ActionEvent)currentEvent).getModifiers();
              ActionEvent ae = new ActionEvent (this, ActionEvent.ACTION_PERFORMED,
                   "VNumber", EventQueue.getMostRecentEventTime(), modifiers);
              // Guaranteed to return a non-null array
              Object[] listeners = listenerList.getListenerList();
              // Process the listeners last to first, notifying those that are interested in this event
              for (int i = listeners.length-2; i>=0; i-=2)
                   if (listeners==ActionListener.class)
                        ((ActionListener)listeners[i+1]).actionPerformed(ae);
         }     //     fireActionPerformed
    }     //     VNumber

    If getValue() returns null, you need to trace the execution of the code and figure out which sequence of code is leading to the return of null. This method looks complex - a lot of if statements. If you do not have a debugger, put System.out.println statements inside the method to figure out what's going on.

Maybe you are looking for

  • I need to install cc on two macs. My Macbook Pro and my Imac. Can I use the same account?

    I have two machines I use. One primarily for photography on the move and another for mostly Indesign work. Question is can I use the same account on both as it will never be simultaneous. Derek

  • No Video Plays From Computer To Apple TV

    Video will no longer play from my computer through the Airport Extreme to my Apple TV.  I can watch streaming video from the internet though. Any suggestions? Thanks. Andy

  • Video, si. Audio, nada.

    I've been able to insert video into an InDesign document and export to PDF but I can't get audio to work. What do I need to do to get the PDF video to play the audio.  I've checked the original video files (H.264) and the audio plays fine.

  • Sequence fps help !!

    Hey Everyone im working in FCP 7.0.3 i have shot some footage on a Canon 5DMKII at 1920x1080 25fps in FCP sequence settings im using. frame size 1920 x 1080 - HDTV 1080i (16:9) pixel aspect - square compressor - apple prores 422 HQ but my editing tim

  • How many songs can itunes handel? Any limit? How to build an big itunes server?

    Hello, i have thousands of Records, CDs etc. Now i want to build for my house an itunes server. Here are my questions: 1. Is there any limit for itunes to handle songs ? 2. I have a lot of Apples, iPhones, iPods - much more than 5. Can they all use t