Notifications
Clear all

[Closed] Null terminated string function

I have a binary files that I need to read certain information from. All the info have static offsets just past the dynamic and null terminated strings like i.e “parrotLeftWing_geoShape_Parrot_Body” in hex “706172726F744C65667457696E675F67656F53686170655F506172726F745F426F647900” and my data readouts follow 1 byte after, then 5 bytes, then 17 and so on.
So my question is , is there a function that returns null terminated string index in the file( so I can use it`s index+length to offset my data readouts)?

here something to help to explain myself

thanks guys

2 Replies

Anyone? I went through the net and mxs help but could not find something that would help me with this. There must be a way to find string indexes in the binary files, no?

this worked for me

fstream = fopen "c:/test.dat" "rb"
if fstream != undefined then
(
	str1 = ReadString fstream;
	str2 = ReadString fstream;
	
	fclose fstream;
)