title: What should I change in FindFirstFile function to make it show me full file names?
body: <p>I'm a student currently learning c++ and I'm doing a course project.</p>
  <p>I'm told to use FindFirstFile function but I can't really understand how it functions and almost blindly made it work somehow. Yet it only shows me the first letters of the files' names. What should I change to make it show me the full names so I could use it later in the program?</p>
  <pre><code>#include &lt;iostream&gt;
  #include &lt;stdio.h&gt;
  #include &lt;stdlib.h&gt;
  #include &lt;math.h&gt;
  #include &lt;Windows.h&gt;
  #include &lt;string.h&gt;
  
  int main()
  {
      WIN32_FIND_DATA FindFileData;
      HANDLE hf;
      system(&quot;chcp 1251&quot;);
  
      hf = FindFirstFile(L&quot;c:\\Program Files (x86)\\*&quot;, &amp;FindFileData);
      if (hf == INVALID_HANDLE_VALUE)
      {
          printf(&quot;Error opening files or no files found!&quot;);
          return 1;
      }
      else
      {
          do
          {
              printf(&quot;Found file: %s&quot;, FindFileData.cFileName);
              printf(&quot;\n&quot;);
          } while (FindNextFile(hf, &amp;FindFileData) != 0);
          FindClose(hf);
      }
  
      system(&quot;pause&quot;);
      return 0;
  }
  </code></pre>
  <p>The example of what it shows: <a href="https://i.stack.imgur.com/Vd9Uk.png" rel="nofollow noreferrer">example of program's output</a></p>