2012-10-12 48 views

回答

5

您可以通過TInputQueryWizardPage.Edits索引屬性訪問它們:

[Code] 
var 
    FirstEditIndex: Integer; 
    SecondEditIndex: Integer; 
    InputPage: TInputQueryWizardPage; 

procedure InitializeWizard; 
begin 
    InputPage := CreateInputQueryPage(wpWelcome, 'Caption', 'Dscription', 'SubCaption'); 

    // the Add method returns the Index of the just added edit box, and 
    // you need to store those indexes to access the edit boxes later on 
    FirstEditIndex := InputPage.Add('Name:', False); 
    SecondEditIndex := InputPage.Add('Surname:', False); 

    // access the edits through the stored indexes; in your case this will 
    // happen in the other event, so take this script as a showcase 
    InputPage.Edits[FirstEditIndex].Enabled := False; 
    InputPage.Edits[SecondEditIndex].Visible := False; 
end; 
相關問題