title: Use one method in another method
body: <p>so this has probably been asked before but i cant really understand all the information i have been reading online.</p>
  
  <pre><code>public static void balanceSheet(){
    //Put in the Company u want to get the data from
    Scanner scan= new Scanner(System.in);
    System.out.println("Enter your Symbol: ");
    String symbol= scan.nextLine();
  
    //Diffrent Websites to visit and get the Data
    String url = ("http://www.morningstar.com/stocks/XNAS/"+symbol+"/quote.html");
    driver.switchTo().frame(driver.findElement(By.xpath("//*[(@id = 'quote_quicktake')]//iframe")));
    String currPrice = driver.findElement(By.id("last-price-value")).getText();
    driver.switchTo().defaultContent();
  
    System.out.println("Current Share Pirce: "+currPrice+"$");
  }
  </code></pre>
  
  <p>how do i get the value of String currPrice inside the calCulator method so i can calculate it with other numbers?</p>
  
  <pre><code>public void calCulator() {
    Scanner calCu = new Scanner(System.in);
    System.out.println("Do you want to Calculate the Value?: ");
    String calculator = calCu.next();
  
    if(calculator.equals("Yes")) {
      System.out.println("the Calculation is: ");
    }
  
    else {
      System.out.println("ok");
    }
  }
  </code></pre>