Errors, bugs, questions - page 899

 
Yedelkin:
Yep. The answer to your question "Does a file have strings?" You already got it.

Yedelkin, I got it when you were still walking under the table.
I'll explain again - it's all about concepts.

person asks a question

lazarev-d-m:
Please tell me how to go to read a new line of data, I can not find the command to move the cursor to a new line, thanks

gets a wrong answer.

So? Yedelkin, do you think this is the answer that will open his eyes to what he wants to model?

Instead of messing with my head with your level of knowledge, you'd better communicate with the man and give him an idea of where to look.


Instead, you jumped into our conversation and started "flaunting" your knowledge of the reference. Not good. Not good.

 
lazarev-d-m:

I understand that there are ways to define an individual string, but no separate command to address it

Why not?

for csv/txt files there is a function FileReadString

that's exactly what you need.

+ (if you open the file as TXT, you'll be more comfortable) then do StringSplit on the read string

--------------------

your code may be full of hang-ups. you should also check FileIsEnding

Документация по MQL5: Файловые операции / FileOpen
Документация по MQL5: Файловые операции / FileOpen
  • www.mql5.com
Файловые операции / FileOpen - Документация по MQL5
 
sergeev:

...

gets the wrong answer.

Well? Yedelkin, do you think that's an answer that will open his eyes to what he wants to model?

About FileSeek() I gave an incorrect answer. I just read the question and made a mistake. )) But then I tried to correct it by this example. It seems to work correctly. Or show me how you would make changes with the same example. Interesting.
 
sergeev: Yedelkin, I got it when you were still walking under the table.
Aha-2 :) Having received a positive answer to your own question ("does the file have strings"?), you have only to assert that the answer is common knowledge. And to hide your incompetence, you have only to throw around "concepts", "levels of knowledge" and "have walked under the table".

I also note your, Sergeev, wonderful logic: "I ask a perplexing question like ("does a file have strings?"), and if I get an unexpectedly positive answer, I tell everyone else that it's all about concepts, and the author of the perplexing question like " does a file have strings?" just wanted to lead everyone else to the right idea that a file has strings". Five points.

 
Yedelkin:
Aha-2 :) Having received an affirmative answer to your own question ("Does a file have strings"?), you have only to assert that the answer is common knowledge. And to hide your incompetence, you have only to throw around "notions" and "levels of knowledge".

I also note your, Sergeev, wonderful logic: "I ask a perplexing question, and if I get an unexpectedly positive answer, I tell everyone else that it's all about concepts, and the author of the perplexing question like " Does a file have strings?" just wanted to lead everyone else to the right idea that a file has strings". Five points.

Yedelkin, there are no strings in a file. (As well as forks in a matrix.) To give simple coders like you the concept of "strings" - smarter creators agreed to use one / two bytes with value =10 and/or=13. Calling them a sign of "what coder wants". In normal situations these bytes are dubbed -"end of line" in quotes for a reason, as the creators called it that way, so encoders understand what to do when these bytes are encountered.

This indication depends on the operating system.

My competence allows me to speak about it. And you seem to be a windbag and demagogue. Once again you show it. You can stay where you are. To pull you higher is not really interesting to me.

---------------

If lazarev-d-munderstands that he has to search for bytes in the file - then he automatically no longer asks about "strings", I suggest using the ready-made function FileReadString, which automatically reads the file to the specified bytes.

 
sergeev: Yedelkin, there areno strings in the file. (As well as forks in matrix). To give simple coders like you a concept of "strings" - more clever creators have agreed to use one/two bytes with value =10 and/or=13. Calling them a sign of "what the coder wants". In normal situations these bytes are dubbed -"end of line" taken in quotes for a reason, as the creators called it that way, so that coders correctly understand what to do when these bytes are encountered.

This feature depends on the operating system.

My competence allows me to speak about it, while you seem to be a windbag and demagogue. You show it once again. You can stay where you are. Pulling you higher is not particularly interesting to me.

---------------

If lazarev-d-munderstands that he needs to search for bytes in the file - then the question about "strings" automatically disappears from his mind. I suggest using the ready-made function FileReadString, which automatically reads the file to the specified sign of "end of line".

I congratulate you. If your "competence" allows you to agree that the answer to your question ("Does file really have strings?") is positive within MQL5, I can only be glad for self-criticism of the author of the"Does file really have strings?". :)
 
tol64:
I gave wrong answer about FileSeek(). I just missed reading the question and made a mistake. )) But then I tried to correct it by this example. It seems to work correctly. Or show me how you would make changes in the same sample. Interesting.

the example for counting the number of lines is just right

but it could be sped up a little, if you open the file as TXT. Then intermediate delimiters (";") would not be taken into account and it would be read immediately "line by line".

 
Yedelkin:
within the MQL5 language
which MQL5 function in particular are you talking about?
 
sergeev:
Which MQL5 function in particular are you referring to?

I've already given you personally this value from the MQL5 language framework:

FILE_LINE_END.

Getting the end of line sign

Do you suggest repeating it a third time?

 
Yedelkin:

I've already brought you personally this from the " MQL5 language framework":

FILE_LINE_END.

Get end of line sign

Are you suggesting to go a third time round?


No. I just made sure once again that it's all about the file perception model.

You think that FILE_ABRA_KADABRA sign means something. I'm sure there is nothing but bytes in the file.


What do you think - what does FileGetInteger function do with request of FILE_LINE_END property ?


Reason: