다음을 통해 공유


Windows Networking API/Redirector Application Development (Windows CE 5.0)

Send Feedback

A Microsoft® Windows® CE–based application can use Windows networking functions to establish and terminate network connections and to access files on servers supporting the Common Internet File System (CIFS). Access to this data is made possible by way of the Windows CE networking API (WNet). WNet communicates through the CIFS, also called Server Message Block (SMB), redirector to the remote host. A CIFS redirector enables one computer to access files on another. An application can use WNet functions to manage network connections anywhere in the network hierarchy.

An application can also access network resources using the Universal Naming Convention (UNC). UNC is a system for naming files on a network so that a file on a computer has the same path when accessed from any other computer. For example \\Servername\Sharename\Filename.ext; Servername is the server name, and Sharename is a directory on Servername that contains the file Filename.ext. Most of the standard Windows CE file APIs (such as CreateFile) work with UNC path names.

  • The Windows CE WNet API is similar to WNet for Windows-based desktop operating systems, with the following exceptions:
  • Windows CE does not support drive letters. The WNet API supports mapping a remote UNC name to a local name, but whereas for the desktop operating systems the local name is drive-based, for example, H:<path>, Windows CE local names may take any form, for example, \Myshare\Path. Local names can be up to 64 characters in length, thus expanding the number of mapped network resources beyond 26.
  • The only network provider currently supported by Windows CE is the Microsoft Windows Network.
  • No connections are automatically restored when the device is warm booted. A persistent connection is stored in the registry and the connection appears in the list of resources. This data is enumerated and retrieved by calling the WNetOpenEnum function with the dwScope parameter set to RESOURCE_REMEMBERED, then calling WnetEnumResource on the returned handle.
  • Windows CE does not expose APIs for mail slots.
  • Windows CE supports only a subset of the full WNet API. For example, the WNet function WNetGetLastError is not supported. This function is redundant because supported WNet functions do not return extended error data. The user can use the GetLastError function. All WNet functions return an ERROR_XXX value. This is not the same as Microsoft Windows NT®, which returns WN_XXX error values. ERROR _XXX error values are mapped to the appropriate WN_XXX error codes for backward compatibility.
  • LAN Manager functions are not exposed.
  • Windows CE does not support the concept of a computer or device belonging to a specific network context.

See Also

Accessing Remote File Systems | Managing Network Connections with WNet | Windows Networking API/Redirector Security | Windows Networking API/Redirector Registry Settings | Windows Networking API/Redirector Functions | Windows Networking API/Redirector Structures

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.