Thread: Question about PropertySheet

  1. #1
    Registered User Joelito's Avatar
    Join Date
    Mar 2005
    Location
    Tijuana, BC, México
    Posts
    310

    Question Question about PropertySheet

    I succesfully create wizard style app..

    But I have a question:

    See my screeny:
    mywizard

    Now, I'd like to see like M$ ones:

    M$

    part of my code:
    Code:
    void CreateWizard(HINSTANCE hInst, HWND hwnd) {
    	PROPSHEETPAGE psp; 
    	PROPSHEETHEADER psh; 
    	HPROPSHEETPAGE hp[1];
    
    	psp.dwSize = sizeof(PROPSHEETPAGE); 
    	psp.dwFlags = PSP_DEFAULT|PSP_HIDEHEADER;
    	psp.hInstance = hInst;
    	
    	// DLG-01 (Welcome page)
    	psp.pszTemplate = MAKEINTRESOURCE(IDD_DIALOG1);
    	psp.pfnDlgProc = (DLGPROC)Page1Proc;
    	hp[0] = CreatePropertySheetPage(&psp);
    
    	// DLG-02 (inner dialog beta page)
    	psp.pszHeaderTitle = "Cabecera";
    	psp.pszHeaderSubTitle = "Subtitulo";
    	psp.dwFlags = PSP_DEFAULT|PSP_USEHEADERTITLE|PSP_USEHEADERSUBTITLE;
    	psp.pszTemplate = MAKEINTRESOURCE(IDD_DIALOG2);
    	psp.pfnDlgProc = (DLGPROC)Page1Proc;
    	hp[1] = CreatePropertySheetPage(&psp);
    
    	ZeroMemory(&psh, sizeof(PROPSHEETHEADER)); 
    	psh.dwSize = sizeof(PROPSHEETHEADER); 
    	psh.dwFlags = PSH_WIZARD97|PSH_USEHEADER|PSH_WATERMARK;
    	psh.pszbmHeader = MAKEINTRESOURCE(IDB_BITMAP1);
    	psh.pszbmWatermark = MAKEINTRESOURCE(IDB_BITMAP2);
    	psh.hInstance = hInst;
    	psh.hwndParent = hwnd;
    	psh.nStartPage = 0;
    	psh.nPages = 2; 
    	psh.phpage = hp; 
    	PropertySheet(&psh);
    	return;
    }
    Any ideas? Right now...my possible solution is to make the welcome bitmap as large as the dialog and add the controls to the inner dialog as far right I can...but I think there's a easier way...does it?
    * PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with xfce4.
    * Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with xfce4.

  2. #2
    erstwhile
    Join Date
    Jan 2002
    Posts
    2,227
    CProgramming FAQ
    Caution: this person may be a carrier of the misinformation virus.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Alice....
    By Lurker in forum A Brief History of Cprogramming.com
    Replies: 16
    Last Post: 06-20-2005, 02:51 PM
  2. Debugging question
    By o_0 in forum C Programming
    Replies: 9
    Last Post: 10-10-2004, 05:51 PM
  3. Question about pointers #2
    By maxhavoc in forum C++ Programming
    Replies: 28
    Last Post: 06-21-2004, 12:52 PM
  4. Question...
    By TechWins in forum A Brief History of Cprogramming.com
    Replies: 16
    Last Post: 07-28-2003, 09:47 PM
  5. Question, question!
    By oskilian in forum A Brief History of Cprogramming.com
    Replies: 5
    Last Post: 12-24-2001, 01:47 AM