{"id":677,"date":"2008-05-20T11:21:06","date_gmt":"2008-05-20T11:21:06","guid":{"rendered":"http:\/\/6teen.ru\/?p=404"},"modified":"2008-05-20T11:21:06","modified_gmt":"2008-05-20T11:21:06","slug":"3439","status":"publish","type":"post","link":"http:\/\/pblog.ru\/lab\/?p=677","title":{"rendered":"\u041a\u0430\u043a \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u043f\u0438\u0441\u043e\u043a \u0444\u0430\u0439\u043b\u043e\u0432 \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u043f\u043e\u0434\u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430\u043c\u0438"},"content":{"rendered":"<p>\u041a\u0430\u043a \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u043f\u0438\u0441\u043e\u043a \u0444\u0430\u0439\u043b\u043e\u0432 \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u043f\u043e\u0434\u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430\u043c\u0438<br \/>\n<!--more--><\/p>\n<pre class=\"alt2\" style=\"margin:0px; padding:6px; border:1px inset; width:580px; height:320px; overflow:auto\"><div>\u041a\u0430\u043a \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u043f\u0438\u0441\u043e\u043a \u0444\u0430\u0439\u043b\u043e\u0432 \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u043f\u043e\u0434\u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430\u043c\u0438\n\nprocedure ScanDir(StartDir: string; Mask:string; List:TStrings);\nvar\nSearchRec : TSearchRec;\nbegin\nif Mask = '' then Mask := '*.*';\nif StartDir[Length(StartDir)] <> '\\' then StartDir := StartDir + '\\';\nif FindFirst(StartDir+Mask, faAnyFile, SearchRec) = 0 then\nbegin\nrepeat\nApplication.ProcessMessages;\nif (SearchRec.Attr and faDirectory) <> faDirectory then\nList.Add(StartDir + SearchRec.Name)\nelse if (SearchRec.Name <> '..') and (SearchRec.Name <> '.') then\nbegin\nList.Add(StartDir + SearchRec.Name + '\\');\nScanDir(StartDir + SearchRec.Name + '\\',Mask,List);\nend;\nuntil FindNext(SearchRec) <> 0;\nFindClose(SearchRec);\nend;\nend;\n\n\u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0437\u043e\u0432\u0430. \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b\n1. \u0438\u043c\u044f \u043f\u0430\u043f\u043a\u0438\n2. \u043c\u0430\u0441\u043a\u0430, \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e *.*\n3. \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435 \u0434\u043b\u044f \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430, \u043b\u044e\u0431\u043e\u0439 \u043d\u0430\u0441\u043b\u0435\u0434\u043d\u0438\u043a \u043e\u0442 TString, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 TStringList\n\nprocedure TForm1.Button1Click(Sender: TObject);\nbegin\nListBox1.Items.Clear;\nScanDir('c:','',ListBox1.Items);\nLabel1.Caption := IntToStr(ListBox1.Items.Count);\nend;\n\n***************************************************************\n\n\u041c\u043e\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 \u0434\u043b\u044f TreeView:\n\n<\/div><\/pre>\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u041a\u0430\u043a \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u043f\u0438\u0441\u043e\u043a \u0444\u0430\u0439\u043b\u043e\u0432 \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u043f\u043e\u0434\u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430\u043c\u0438<\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[448,459],"tags":[1258,1564,913,326,345],"_links":{"self":[{"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=\/wp\/v2\/posts\/677"}],"collection":[{"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=677"}],"version-history":[{"count":0,"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=\/wp\/v2\/posts\/677\/revisions"}],"wp:attachment":[{"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=677"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=677"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=677"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}