private void updateStock(){
		while(true){
			
			//Sets a new price for a choosen company.
			switch(stockName){
			case "AAPL": stockBase.setAaplPrice(format(defaultPrice+generatePriceChange())); 
			break;
			case "GOOG": stockBase.setGoogPrice(format(defaultPrice+generatePriceChange()));
			break;
			case "IBM": stockBase.setIbmPrice(format(defaultPrice+generatePriceChange()));
			break;
			default: System.out.println("Can't find "+stockName);
			}
			
			//Pause.
			try {
				Thread.sleep(changeFreq);
			} catch (InterruptedException e) {}
		}
	}