Type a page name and press Enter. You'll jump to the page if it exists, or you can create it if it doesn't.
To create a page in a module other than rapi, prefix the name with the module name and a period.
CE_FIND_DATA (rapi)
rapi is for smart devices, not desktop Windows. Therefore, this information only applies to code using the .NET Compact Framework. To see if information for CE_FIND_DATA in other DLLs exists, click on Find References to the right.
.
C# Signature:
[StructLayout(LayoutKind.Explicit,CharSet=CharSet.Unicode)]
public struct CE_FIND_DATA
{
[FieldOffset( 0)] public uint dwFileAttributes;
[FieldOffset( 4)] public FILETIME ftCreationTime;
[FieldOffset( 12)] public FILETIME ftLastAccessTime;
[FieldOffset( 20)] public FILETIME ftLastWriteTime;
[FieldOffset( 28)] public uint nFileSizeHigh;
[FieldOffset( 32)] public uint nFileSizeLow;
[FieldOffset( 36)] public uint dwOID;
[MarshalAs(UnmanagedType.ByValTStr,SizeConst=260),FieldOffset(40)] public string Name;
};
Note :
FILETIME is now obsolet. You can use System.Runtime.InteropServices.ComTypes.FILETIME type instead.
VB Signature:
<StructLayout(LayoutKind.Sequential, pack:=4, CharSet:=CharSet.Unicode)> _
Public Structure CE_FIND_DATA
Public dwFileAttributes As Integer
Public ftCreationTime As FILETIME
Public ftLastAccessTime As FILETIME
Public ftLastWriteTime As FILETIME
Public nFileSizeHigh As Integer
Public nFileSizeLow As Integer
Public dwOID As Integer
<MarshalAs(UnmanagedType.ByValTStr, sizeConst:=MAX_PATH)> _
Public cFileName As String
End Structure
TODO
User-Defined Types:
None needed
Tips & Tricks:
MAX_PATH is set to 260 characters by Windows so we create a ByValTStr with this length. Can then just use the 'Name' field as a normal string
Sample Code:
int hFile;
CE_FIND_DATA Data=new CE_FIND_DATA();
hFile=CeFindFirstFile("\\My Documents",ref Data);
return (hFile!=0);
Alternative Managed API:
Do you know one? Please contribute it!
This function searches a directory for a file whose name matches the specified filename. It examines subdirectory names as well as filenames.
10/20/2009 3:46:44 AM - -150.161.2.213
This function continues a file search from a previous call to the CeFindFirstFile function.
4/15/2009 9:06:23 AM - -217.109.85.156
Please edit this page!
Do you have...
helpful tips or sample code to share for using this API in managed code?
corrections to the existing content?
variations of the signature you want to share?
additional languages you want to include?
Select "Edit This Page" on the right hand toolbar and edit it! Or add new pages containing supporting types needed for this API (structures, delegates, and more).