title: Error reading my csv file in class in Java Application
body: <p>I need to read a sample.csv file from the same class as my main. 
  Below you can see the structure. </p>
  
  <p><a href="https://i.stack.imgur.com/dIkgR.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/dIkgR.png" alt="enter image description here"></a>
  This is my code but when I run it it gave me the error that the sample.csv is not find!</p>
  
  <pre><code>public int convertFile(String csvFileName, String xmlFileName,
                      String delimiter) {
          int rowsCount = -1;
          BufferedReader csvReader;
          try {
              Document newDoc = domBuilder.newDocument();
              // Root element
              Element rootElement = newDoc.createElement("XMLCreators");
              newDoc.appendChild(rootElement);
              // Read csv file
              csvReader = new BufferedReader(new FileReader(csvFileName));
              CSVReader reader = new CSVReader(new FileReader("sample.csv"));
              //CSVReader reader = new CSVReader(csvReader);
              String[] nextLine;
              int line = 0;
              List&lt;String&gt; headers = new ArrayList&lt;String&gt;(5);
              while ((nextLine = reader.readNext()) != null) {
  ....
  
  </code></pre>
  
  <p>Can anyone suggest me what is the problem?</p>