MFC Dialog - Klasse erstellen?



  • Hi. Ich folge gerade einer Anleitung um ein TabCtrl zu benutzen, leider komme ich aber hierbei nicht mehr weiter.
    Ich habe zwei Dialoge (Fenster?) erstllt und entsprechend der Anleitung eingestellt.
    Jedoch jedesmal wenn ich im Resourceneditor die Form angeklickt habe und den Klassenwizard aufrufe um dann eine Klasse zu erstellen kann ich das ganze nicht mehr kompilieren, da der Compiler im AFX_ Bereich stehenbleibt und mir sagt, dass IDD_DIALOG1 (bzw IDD_DIALOG2) nicht existiert.. gibt es da einen besonderen Trick um das ganze zu schaffen?

    * Create two Dialog boxes by using the Visual Studio --> Menu --> Insert Resource --> Dialog.
    * Ensure that their ids are IDD_DIALOG1, IDD_DIALOG2. The sample in this article uses these IDs marked in Blue.
    * Put some controls or some sample text on the dialog boxes for differentiating both of them from each other.
    * For both the dialogs, set the Properties Dialog --> Styles --> Style equal to Child.
    * Also Un-check the Properties Dialog --> Styles --> Title bar and System Menu. They should be set to false. Because the tab sheets cannot have a title bar.
    * Set the Properties Dialog --> More Styles --> Visible style to True.
    * For both the dialogs create two dialog classes by using the class wizard.

    Danke im Vorraus :0)



  • Ok.. Wie immer wars nur ein sehr kleiner Fehler.. musste in die *.h Datei der neuen klasse die resource.h includen 😑


Anmelden zum Antworten