1

I have a CDialog class and i need it to be called by a sum of other classes, at the same time. This should work from what i understand, but it would be the same instance of the Dialog, and i need as many different instances as calling classes. Is this possible?

MRM
  • 561
  • 5
  • 12
  • 29

1 Answers1

2

Each dialog window displayed on the screen simultaneously must have a different CDialog derived object associated with it. They may all be the same class, with the same resource ID, but they must be different objects.

Mark Ransom
  • 299,747
  • 42
  • 398
  • 622
  • So, if a member of an object changes it's state, this won't reflect in the state of other same objects? – MRM Jul 27 '12 at 15:17
  • @MRM, yes that's the difference between a class and an object. Each object has its own members that are distinct from other objects of the same class. – Mark Ransom Jul 27 '12 at 15:24