Hi,

I am getting the following error while compiling the code on linux machine.

"aggregate value used where an integer was expected"

I am getting this error on a simple for loop. I do not know the reason for this error.
Any help is appreciated.

Thanks

Try converting the value using static_cast<int>(yourvalue) ...

Showing some code would be helpful.

I'm betting you're trying to assign to an array or structure, or trying to pass an array or structure to a function that takes an integer or...could be lots of things.

>Try converting the value using static_cast<int>(yourvalue) ...
Casting is the worst possible reaction to an error like this. Putting a dirty plate in a stack of clean plates doesn't make it clean.

Could you please post your code ?