Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6101011
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T13:27:05+00:00 2026-05-23T13:27:05+00:00

I have many Windows CE 5 devices in the field, running our software. Part

  • 0

I have many Windows CE 5 devices in the field, running our software.

Part of their duty is to zip up some directories, and send to the server.

On about 3 (of several hundred) devices, I get this error, consistently, when trying to zip up a directory. The zipping process involves descending through every subdirectory and adding the files.

System.IO.IOException: IOException
   at System.IO.__Error.WinIOError(Int32 errorCode, String str)
   at System.IO.Directory.InternalGetFileDirectoryNames(String fullPath, Boolean file)
   at System.IO.Directory.InternalGetDirectories(String path, String searchPattern)
   at System.IO.Directory.GetDirectories(String path, String searchPattern)

This happens every time on this device – not random.

Copying the directory contents to my development device, and running the same (on the same directory contents) does NOT cause the error. I do not have the actual device to debug interactively.

Of course, this WinIOError is not very useful in terms of determining actual cause. Can anyone give me any hints as to what could cause the CF to fail so spectacularly when just trying to read the directory contents?

As you can see below, common things like the directory no longer existing are handled by a specific exception to that effect – not the generic WinIOError.

Many thanks for any clues.

Below is the disassembled function:

// System.IO.Directory
    internal static string[] InternalGetFileDirectoryNames(string fullPath, bool file)
    {
      char c = fullPath[fullPath.Length - 1];
      if (c == Path.DirectorySeparatorChar || c == Path.AltDirectorySeparatorChar || c == Path.VolumeSeparatorChar)
      {
        fullPath += '*';
      }
      string[] array = new string[10];
      int num = 0;
      HostNative.FIND_DATA fIND_DATA = new HostNative.FIND_DATA();
      if (!Directory.Exists(Path.GetDirectoryName(fullPath)))
      {
        throw new DirectoryNotFoundException();
      }
      int handle;
      int num2 = PAL.File_OpenAndReadDir(fullPath, out handle, fIND_DATA);
      if (num2 != 0)
      {
        if (num2 == -2147479552 || num2 == -2147479545)
        {
          return new string[0];
        }
        __Error.WinIOError(num2, Path.GetDirectoryName(fullPath));
      }
      int num3 = 0;
      do
      {
        bool flag;
        if (file)
        {
          flag = (0 == (fIND_DATA.dwFileAttributes & 16));
        }
        else
        {
          flag = (0 != (fIND_DATA.dwFileAttributes & 16));
          if (flag && (fIND_DATA.cFileName.Equals(".") || fIND_DATA.cFileName.Equals("..")))
          {
            flag = false;
          }
        }
        if (flag)
        {
          num3++;
          if (num == array.Length)
          {
            string[] array2 = new string[array.Length * 2];
            Array.Copy(array, 0, array2, 0, num);
            array = array2;
          }
          array[num++] = fIND_DATA.cFileName;
        }
        num2 = PAL.File_ReadDir(handle, fIND_DATA);
      }
      while (num2 == 0);
      PAL.File_CloseDir(handle);
      if (num2 != 0 && num2 != -2147479545)
      {
        __Error.WinIOError(num2, Path.GetDirectoryName(fullPath));
      }
      if (!file && num3 == 1 && (fIND_DATA.dwFileAttributes & 16) != 0)
      {
        return new string[]
        {
          fIND_DATA.cFileName
        };
      }
      if (num == array.Length)
      {
        return array;
      }
      string[] array3 = new string[num];
      Array.Copy(array, 0, array3, 0, num);
      return array3;
    }
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T13:27:06+00:00Added an answer on May 23, 2026 at 1:27 pm

    Physically broken storage media might cause this. Low quality SD card, by any chance?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a computer running Windows and connected with many devices, such as a
Im using c# .net windows form application. I have many databases created using sql
I have found many tutorials about using Windows Server 2003 as a development machine,
I have created a fairly substantial Java GUI application with many form windows where
Wondering how to open many new windows with Javascript. I have found plenty of
Im using c# .net windows application form. I have created many databases with many
Noob question, apologies. I'm compiling Java in Windows Vista's command-line and have so many
I have a directory of many files in Windows Vista. I'd like in a
I have not used Windows Vista. I knew that many APIs have been changed/deprecated
I have a form MainForm which is a Windows Forms form that contains many

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.