I have made a string vector
vector<string> actor_;
and then added elements in it using push_back.
I now want to display all of them, for which I need to run a loop according to the number of elements in the vector. For that, I need to run the following loop:
for (int i = 0; i < (int)actor_.size; i++)
{
}
but this returns the following error:
error C2440: 'type cast' : cannot convert from 'unsigned int (__thiscall std::vector<_Ty>::* )(void) const' to 'int'
1> with
1> [
1> _Ty=std::string
1> ]
1> There is no context in which this conversion is possible