0
Can anyone help me with this question? I wanted to read all the keys of a section in a file ". ini" and use them as string.
Ex:
[ITENS]
pedido1 = 3552
pedido2 = 2208
pedido3 = 2066
pedido4 = 5787
pedido5 = 2966
pedido6 = 8889
Return: String array[] = [pedicle1, pedicle2, pedicle3, pedicle4, pedicle5, pedicle6]
I already use Getprofilestringa from "windows. privateh" to get a value from a key, but had trouble getting the name of all keys.
I’m kind of beginner. I tried it like this. I have difficulties converting variables. In the language I used it was all sort of automatic string system = "requested 1 = 3552 0requested 2 = 2208 0requested 3 = 2066 0"; Std::vector<Std::string> keys; for(const char *result = system; strlen(result); result += strlen(result) + 1) keys.push_back(Std::string(result, (int)(result, '=') - result)));
– Pedro A. Pinheiro
This is an example, but in this example, use char*system = ...
– sbrubes