Pulling commas from data to store in a CSV file

Joined
Jun 17, 2024
Messages
3
Reaction score
0
I have a line of code that I think should pull the commas out of an integer, turn it to a string and remove the comma and was wondering if there was a better way to do this?

AUTH.lease.operator.indexList := TextToInt(Strip(Left(line,commaPointer),'#'),10)
 
Joined
Dec 10, 2022
Messages
80
Reaction score
24
That looks like part of a larger code. It will do nothing by itself as it's out of context.
 
Joined
Jun 17, 2024
Messages
3
Reaction score
0
Here is the entire routine. I understand what they are doing except for the strip part. Im not sure exactly what language this is because Ive never seen this in C before so Im assuming its either Pythion or something to that extent.

int dataFile := OpenFile("/DATA/operators.csv", 1);
int i := 1;
int commaPointer := 0;

cstring line := ReadFileLine(dataFile);

while(line != "")
{
commaPointer := Find(line,',',0);
AUTH.lease.operator.indexList := TextToInt(Strip(Left(line,commaPointer),'#'),10);
AUTH.lease.operator.nameList := Strip(Right(line,Len(line)-commaPointer-1),'#');
line := ReadFileLine(dataFile);
i++;
}

AUTH.lease.scrollMenu.minLength := i;
AUTH.lease.operator.lastListedIndex := AUTH.lease.operator.indexList[i-1];

CloseFile(dataFile);
 
Joined
Apr 5, 2023
Messages
1
Reaction score
0
It appears to be written in 4GL Fourth Generation Language used by OpenROAD (also known as OpenROAD 4GL)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,818
Messages
2,569,727
Members
45,664
Latest member
Phil79581

Latest Threads

Top