Category : dynamic

The code gives a breakpoint and I have figured out that there is some problem in the destructor but can’t really get to a solution.Here is my code: class Voter { private: static int totalvotes; int individualvotes; int id; char* name; char* CNIC; public:Voter(); Voter(int ide, int indvotes ,char* nam, char* cnic); void setid(int x); ..

Read more

So I’m working on a SFML Application and in this example I want to create an object of type Rectangleshape when the key ‘A’ is pressed. As you can see I have a vector that stores all created Rectangles to display them. I tried using pointers, but that didn’t work, partly because the window.draw() method ..

Read more