Главная страница
    Top.Mail.Ru    Яндекс.Метрика
Форум: "Основная";
Текущий архив: 2005.06.14;
Скачать: [xml.tar.bz2];

Вниз

Ошибка: Symbol faReadOnly is specific to a platform   Найти похожие ветки 

 
lucifer ©   (2005-05-31 18:11) [0]

Взял пример из хёлпа Делфи :

The following example uses an edit control, a button, a string grid, and seven check boxes. The check boxes correspond to the seven possible file attributes. When the button is clicked, the path specified in the edit control is searched for files matching the checked file attributes. The names and sizes of the matching files are inserted into the string grid.

procedure TForm1.Button1Click(Sender: TObject);

var
 sr: TSearchRec;
 FileAttrs: Integer;
begin
 StringGrid1.RowCount := 1;
 if CheckBox1.Checked then
   FileAttrs := faReadOnly
 else
   FileAttrs := 0;
 if CheckBox2.Checked then
   FileAttrs := FileAttrs + faHidden;
 if CheckBox3.Checked then
   FileAttrs := FileAttrs + faSysFile;
 if CheckBox4.Checked then
   FileAttrs := FileAttrs + faVolumeID;
 if CheckBox5.Checked then

   FileAttrs := FileAttrs + faDirectory;
 if CheckBox6.Checked then
   FileAttrs := FileAttrs + faArchive;
 if CheckBox7.Checked then

   FileAttrs := FileAttrs + faAnyFile;

 with StringGrid1 do
 begin
   RowCount := 0;

   if FindFirst(Edit1.Text, FileAttrs, sr) = 0 then

   begin
     repeat
       if (sr.Attr and FileAttrs) = sr.Attr then
       begin
       RowCount := RowCount + 1;
       Cells[1,RowCount-1] := sr.Name;
       Cells[2,RowCount-1] := IntToStr(sr.Size);
       end;
     until FindNext(sr) <> 0;
     FindClose(sr);
   end;
 end;
end;

и возникает следующая ошибка из темы!
В принципе прога работает, но файлы не ищет! Что скажите??


 
Cobalt ©   (2005-05-31 18:27) [1]

2 lucifer ©
Учите английский - "Warning" переводится не как "ошибка".


 
Marser ©   (2005-05-31 18:45) [2]

Это всего лишь предупреждение о привязанности к ОС этой константы.


 
raidan ©   (2005-05-31 20:05) [3]

>lucifer ©   (31.05.05 18:11)  
Это значит, что в Kylix ваша программа вряд-ли скомпилится в рабочий продукт.


 
begin...end ©   (2005-05-31 20:19) [4]

> raidan ©   (31.05.05 20:05) [3]

Это ужасно :))


 
Igorek ©   (2005-05-31 20:52) [5]

$IFDEF KYLIX - вроде есть такое


 
raidan ©   (2005-05-31 21:10) [6]

>begin...end ©   (31.05.05 20:19) [4]
А я вот люблю экстрим и всегда кладу болт на такие предупреждения.
Или, может быть, я не собираюсь ничего делать под Kylix :)


 
Anatoly Podgoretsky ©   (2005-05-31 21:30) [7]

Класть не надо, надо отключить



Страницы: 1 вся ветка

Форум: "Основная";
Текущий архив: 2005.06.14;
Скачать: [xml.tar.bz2];

Наверх





Память: 0.46 MB
Время: 0.049 c
14-1116781286
raidan
2005-05-22 21:01
2005.06.14
Вести в 20.00 от 22 мая


14-1116861462
Ломброзо
2005-05-23 19:17
2005.06.14
ГОСТ 21552-84


14-1117085786
yk
2005-05-26 09:36
2005.06.14
Хороший стиль программирования


1-1116942271
Rule
2005-05-24 17:44
2005.06.14
коллекция или массив в OLE Automation Object, как сделать ?


9-1110629897
nor
2005-03-12 15:18
2005.06.14
Какой язык выбрать ?





Afrikaans Albanian Arabic Armenian Azerbaijani Basque Belarusian Bulgarian Catalan Chinese (Simplified) Chinese (Traditional) Croatian Czech Danish Dutch English Estonian Filipino Finnish French
Galician Georgian German Greek Haitian Creole Hebrew Hindi Hungarian Icelandic Indonesian Irish Italian Japanese Korean Latvian Lithuanian Macedonian Malay Maltese Norwegian
Persian Polish Portuguese Romanian Russian Serbian Slovak Slovenian Spanish Swahili Swedish Thai Turkish Ukrainian Urdu Vietnamese Welsh Yiddish Bengali Bosnian
Cebuano Esperanto Gujarati Hausa Hmong Igbo Javanese Kannada Khmer Lao Latin Maori Marathi Mongolian Nepali Punjabi Somali Tamil Telugu Yoruba
Zulu
Английский Французский Немецкий Итальянский Португальский Русский Испанский