我是个绝对新手,现在我刚学sdk,正在练习做个程序,要求是这样的
1把系统当前可以用的盘列出来(如c: d: e: 等等)
2选择某一盘符,把该系统盘下当前目录和文件列出来.
3选择某一目录需要列出该目录下一层的目录和文件
4可以回到上一层目录我现在的思路是先把窗口做出来在进行布件
请大家帮我看看编程的思路是什么?如何使用控件?
因为新手,问题问的比较简单
希望大家详细的介绍一下
谢谢
1把系统当前可以用的盘列出来(如c: d: e: 等等)
2选择某一盘符,把该系统盘下当前目录和文件列出来.
3选择某一目录需要列出该目录下一层的目录和文件
4可以回到上一层目录我现在的思路是先把窗口做出来在进行布件
请大家帮我看看编程的思路是什么?如何使用控件?
因为新手,问题问的比较简单
希望大家详细的介绍一下
谢谢
解决方案 »
- VC中使用Shockwave flash object 控件,如何控制flash按帧播放
- 请问高手,树形控件一次可以选中两个节点吗?
- 函数体内变量与对象生命期问题
- 请问大家有什么第三方控件可以播放(vcd,dvd,rm,avi)等视频格式的文件,谢谢!
- 大家帮个忙,帮我讨论一下,应该怎么实现?
- 救命,,如何取得文件名啊...(高分,解决问题的将送100分以上)
- 怎樣才能躍過這一關?
- VC中调用在matlab中实现的com组件,如何使该程序脱离matlab环境?
- 没有可用于当前位置的源码
- 我按UDP协议,发送消息给对方,需要用CAsyncSocket中的connect()这个函数吗?
- 模式对话框不能退出的问题,请大家帮忙
- 小问题,这个问题谁解决有100分的!!!急!!!!!!!!!!!!
控件肯定是使用listctrl了。
请问怎么处理?
GetLogicalDriveStrings
FindFirstFile
FindNextFile用GetLogicalDriveStrings得到盘符,当选中盘符后,用FindFirstFile得到第一个文件或目录,然后利用循环和FindNextFile函数得到其余文件(包括目录)
请问GetLogicalDriveStrings函数的具体用法在那里能找到阿
谢谢
谢谢
谢谢
The GetLogicalDriveStrings function fills a buffer with strings that specify valid drives in the system. DWORD GetLogicalDriveStrings(
DWORD nBufferLength, // size of buffer
LPTSTR lpBuffer // pointer to buffer for drive strings
);
Parameters
nBufferLength
Specifies the maximum size, in characters, of the buffer pointed to by lpBuffer. This size does not include the terminating null character.
lpBuffer
Pointer to a buffer that receives a series of null-terminated strings, one for each valid drive in the system, that end with a second null character. The following example shows the buffer contents with <null> representing the terminating null character.
c:\<null>d:\<null><null>
Return Values
If the function succeeds, the return value is the length, in characters, of the strings copied to the buffer, not including the terminating null character. Note that an ANSI-ASCII null character uses one byte, but a Unicode null character uses two bytes. If the buffer is not large enough, the return value is greater than nBufferLength. It is the size of the buffer required to hold the drive strings. If the function fails, the return value is zero. To get extended error information, use the GetLastError function. 函数的用法vc的帮助中都有啊?
谢谢
这里也谢谢其他兄弟!~
发分了