i'm getting this error (candidate functions not accesible) when trying to use get/set methods from file Allformvariables.h in MyForm.h
I'm putting variables in a seperate class to the form because i want to use the same variables in multiple different forms (at different times) and so im using a private scope for the variables and have my get/set methods as public.
However for some reason i get the error in title when building it.
i have tried #pragma make_public(type) but not sure if i was using the right type or putting it in the right place...
if you need code i will put it in but its larger than i like to put in posts. any help would be greatly appreciated.
This is for my A2 computing project so i really need it done but can't figure it out
I think that the message means that the compiler found the best appropriate function to call but the funcion either has private or protected access control that is it is inaccessible from the code where it is called.
well thats what i figured aswell. but both the functions are all set as public and i still get the error. I know that VS 2012 sets all native types as Private but when i try to override them using #pragma make_public(type) it dosn't change anything.
I suspect i'm probably using that wrong but i can't figure out any other way to do it.
i thought that because the functions Setfloat and Setchar were public i would be able to access them using the Variables instance in my main form.
That is the problem though so thank you for pointing that out.
Is there anyway i could make that a protected function and still be able to use it or does it have to be public??
I am a beginner at this as i said im doing my A2 computing course which is 2nd year of college and my tutors pretty useless at this so i have to ask for outside help if i get stuck. But thanks for the help you've already given