title: passing a input file as a parameter
body: <p>I really need help on my java project. My problem is that I am new to Java and I can't figure out how to pass a input file in java. </p>
  
  <p>I need to open a .dat file, read the file, and set it as a named constant so I can pass it to other methods as a string.</p>
  
  <p>For example I want to open myFle.dat in my beginning method and pass it to a method like this so I can work with it their</p>
  
  <pre><code>doMethod(fileString);
  </code></pre>
  
  <p>If possible talk simple java to me because I am new to this.</p>