There are a few things going on here.
- Directories in Windows (desktop and CE) are delimited by the backslash '\' character, not the forward slash. Desktop Windows might not mind it, but Windows CE isn't going to like it.
- Windows CE has no notion of drive letters (or current directory for that matter) so your path is invalid for that reason as well.
- The CF
FileStream
doesn't expose the file handle, and I'd say for likely good reasons. That's the specific reason for the error you see. Messing with the handle outside of the managed stream can cause the managed side of things to get into an indeterminate state and lead to bad things. Why, exactly, do you need that handle? If we know that, maybe we can propose a workaround, but generally using that native handle is going to lead to bad things happening.