...s\n",Name);//因为16的十六进制是10,文件名会是: ~xx10.tmp//Name = C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\~xx10.tmpGetWindowsDirectory函数与GetSystemDirectory函数用法一样GetWindowsDirectory是获取Windows文件夹的路径。GetSystemDirectory是获
...ot;),0)if (hIcon &&hIcon!=(HICON)-1)pDC->DrawIcon(10,10,hIcon)}说明: 获得notepad.exe的路径正规上来说用GetWindowsDirectory函数得到, 如果是调用 win95下的画笔,应该用访问注册表的方法获得其路径,要作成一个比较考究的程序,考虑应该全面点. (4) 获得各种目录信息Windows目录: Use "GetWin...
...ot;),0)if (hIcon &&hIcon!=(HICON)-1)pDC->DrawIcon(10,10,hIcon)}说明: 获得notepad.exe的路径正规上来说用GetWindowsDirectory函数得到, 如果是调用 win95下的画笔,应该用访问注册表的方法获得其路径,要作成一个比较考究的程序,考虑应该全面点.(4) 获得各种目录信息Windows目录: Use "GetWind...
...s\n",Name);//因为16的十六进制是10,文件名会是: ~xx10.tmp//Name = C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\~xx10.tmpGetWindowsDirectory函数与GetSystemDirectory函数用法一样GetWindowsDirectory是获取Windows文件夹的路径。GetSystemDirectory是获
...到的API函数都是返回系统信息的。先给出在Visual C#中声明API的方法: [DllImport("kernel32")]public static extern void GetWindowsDirectory(StringBuilder WinDir,int count); 其中,"DllImport"属性用来从不可控代码中调用一个方法,它指定了DLL的位置,该DLL中包含调用的外部方...
...ength()-strName.GetLength()-4);returnstrPath;}002获取小手光标voidCHoverButton::SetHandCursor(){CStringstr;GetWindowsDirectory(str.GetBuffer(MAX_PATH),MAX_PATH);str.ReleaseBuffer();str+=_T("\\winhlp32.exe");//loadcur...
...uot;;} // Windows 文件夹AnsiString GetWindowsDir(){String path;path.SetLength(MAX_PATH);path.SetLength(GetWindowsDirectory(path.c_str(),path.Length())); return path;} // System 文件夹AnsiString GetSystemDir(){String path...
...op:=ypanel-ylabel; [DELPHI] WINDOWS uses shellapi; var windir:array[0..255] of char; getwindowsdirectory(windir,sizeof(windir)); HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\Curr...
...xlabel;label.top:=ypanel-ylabel; ◇[DELPHI]取得WINDOWS目录uses shellapi;var windir:array[0..255] of char;getwindowsdirectory(windir,sizeof(windir));或者从注册表中读取,位置:HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersionSys...
...Path //获取临时目录;GetCurrentDirectory //获取当前目录;SetCurrentDirectory //设置当前目录;GetSystemDirectory //获取系统目录;GetWindowsDirectory //获取Windows目录; 使用API 函数SHGetSpecialFolderLocation,shlobj.h里有SHGetSpecialFolderLocation的原型声明。这个函数可以帮...