In general, so, there is a file where do db.txt data come from
1 Бла1 Бла2 Бла3 2 Бла6 Бла5 Бла4 3 Бла7 Бла8 Бла9 4 Бла12 Бла11 Бла10
And each number has its own picture. Number, I understand the question ID, and Bla * the correct answers. I click on the start button. I generate a random number v: = Random (3) +1 from 1 to 4. I display a picture according to the number Img.Picture.LoadFromFile ('img / img _' + v + '. Jpg'); Also next to the picture there are 3 text entry fields where the correct answers should be entered. So my task. Get a random number, open the file and find there a line with this number, get the corresponding answers, then compare them with the entered values in the text input fields. If possible, the number already used should be excluded from use. Those. if the number 3 was generated, and the answer is received, so that the number 3 in the next. once it was ignored, but something else was not displayed. Vooot. Please help! Here is my listing:
v:=Random(3)+1; //Получаем случайное число Img.Picture.LoadFromFile('img/img_'+v+'.jpg'); //Выводим соответствующую картинку AssignFile(fdb,'db.txt'); reset(fdb); //Открываем файл для чтения read(fdb,vid,otv1,otv2,otv3); //Назначаем переменные {Здесь какой-то код, который ищет строку с номером V}