1、file->other->delphi project->devexpress wizard Application按确定
2、设置dxWizardControl1的ViewStyle为wcvsAero
3、设置dxwizardcontrolpage1.Header.Description:='描述'
设置dxwizardcontrolpage1.Header.DescriptionVisible:=True
设置dxwizardcontrolpage1.Header.Title:='标题'
4、右键dxWizardControl1的New Page
高亮dxwizardcontrolpage1
设置Header.Description:='描述1'
设置Header.DescriptionVisible:=True
设置Header.Title:='标题1'
5、设置dxWizardControl1的Buttons属性:Cancel.visible:=false;Help.visible:=false;
6、选中dxwizardcontrolpage1添加dxRadioGroup 控件,添加4个items,分别设置caption以及value属性 ,并设置form1.contrain.minheigth:=330;form1.contrain.min=370;代码如下:
var
Form1: TForm1;
tmpstrlist:tstringlist;
implementation
{$R *.dfm}
procedure TForm1.cxRadioGroup1PropertiesChange(Sender: TObject);
var
tmpstr:string;
begin
tmpstr:=vartostr(self.cxRadioGroup1.EditingValue);
if tmpstrlist.Count< self.dxWizardControlPage1.PageIndex then
tmpstrlist.Add(tmpstr)
else
tmpstrlist.Strings[self.dxWizardControlPage1.PageIndex -1]:=tmpstr;
end;
procedure TForm1.dxWizardControl1ButtonClick(Sender: TObject;
AKind: TdxWizardControlButtonKind; var AHandled: Boolean);
begin
if akind=wcbkFinish then
begin
showmessage('Your answer is:'+#13#10+tmpstrlist.Text)
end;
end;
procedure TForm1.FormCreate(Sender: TObject);
begin
tmpstrlist:=tstringlist.Create;
end;
procedure TForm1.FormDestroy(Sender: TObject);
begin
freeandnil(tmpstrlist);
end;