/echo -a $read(file.txt,s,"50479")
/echo -a $read(file.txt,S,"50479")
The capital S returns the first line text, but it also does that even if I do:
//echo -a $read(file.txt,S,xyz)
From mirch.hlp, small-s "Scans the file info.txt for a line beginning with the word your_word and returns the text *following* the match value."
Since your line has no spaces in it, then there's no following word to find. If you put the entire line#1 into a %variable, and then did:
//echo -a $read(file.txt,s,%variable) . $readn
... you will see that even without returning the text, it did identify the correct line.
Perhaps you should instead use: //echo -a $read(file.txt,w,"50479"*)