0
I am developing a C program that will work with 02 files .txt
The first file, is a report, that goes straight out of the system, and in it are information like item code, location and quantity in stock, this information is in the same line...
The product code, occupies at most the first 14 characters of the string, and I used the following code to remove it from the .txt
:
memcpy( cod, &c[0], 14);
cod[15] = '\0';
However, following the line, I have more information that I wanted to allocate in other variables, to pass them to the second file .txt
, which I will use as output for a Zebra printer.
How do I access the characters from position 15 onwards, and copy them to a variable?
Did any of the answers solve your question? Do you think you can accept one of them? Check out the [tour] how to do this, if you haven’t already. You would help the community by identifying what was the best solution for you. You can accept only one of them. But you can vote on any question or answer you find useful on the entire site (when you have enough score).
– Maniero