WizardReq TITLE "Fax Template Wizard" LABEL "This Wizard will create a Fax template which can then be" LABEL "used with the New command (Project menu)." LABEL " Click Next or press Enter to continue to the next step" LABEL " click Previous to return to the previous step, if available" LABEL " click Cancel to quit without creating a fax or" LABEL " click Finish to create a fax using the default parameters." BUTTON 1 "_Next" BUTTON 3 "_Finish" BUTTON "-1" "_Cancel"
if (Result = -1) THEN
EXIT
if (Result = 3) THEN
SIGNAL FINISH
/* Step 1 */
STEP1:
WizardReq TITLE "Fax Template Wizard" LABEL "What type of facsimile template would you like to produce." LABEL "" LABEL " Click Plain to produce a normal facsimile template," LABEL " Click Stylish to create a fancy looking facsimile." BUTTON 1 "P_lain" BUTTON 2 "_Stylish" BUTTON 3 "_Previous" BUTTON 4 "_Finish" BUTTON "-1" "_Cancel"
if (Result = "-1") THEN
EXIT
if (Result = 1) THEN DO
templatetype = "plain"
SIGNAL STEP2
END
if (Result = 2) THEN
DO
templatetype = "stylish"
SIGNAL STEP2
END
if (Result = 3) THEN
SIGNAL START
if (Result = 4) THEN
SIGNAL FINISH
/* Step 2 */
STEP2:
WizardReq TITLE "Fax Template Wizard" LABEL "Please type in your personal details:" TEXTBOX 1 "N_ame:" CONTENTS deffaxname TEXTBOX 2 "P_osition:" CONTENTS defposition TEXTBOX 3 "_E-mail:" CONTENTS defemail BUTTON 1 "_Next" BUTTON 2 "_Previous" BUTTON 3 "_Finish" BUTTON "-1" "_Cancel"
WizardReq TITLE "Fax Template Wizard" LABEL "Please type in the details of the fax recipient:" TEXTBOX 1 "N_ame:" CONTENTS defrecname TEXTBOX 2 "C_ompany:" CONTENTS defreccompany TEXTBOX 3 "_Telephone:" CONTENTS defrectelephone TEXTBOX 4 "Fac_simile:" CONTENTS defrecfacsimile BUTTON 1 "_Next" BUTTON 2 "_Previous" BUTTON 3 "_Finish" BUTTON "-1" "_Cancel"
buttonresult = Result
if (buttonresult = -1) THEN
EXIT
if (buttonresult = 2) THEN DO
defcompany = company
defaddress1 = address1
defaddress2 = address2
defaddress3 = address3
defpostcode = postcode
defcountry = country
deftelephone = telephone
deffacsimile = facsimile
SIGNAL STEP3
END
/* Get and store results */
Wizard_GetTextBox 1
IF Result ~= "" THEN
recname = Result
Wizard_GetTextBox 2
IF Result ~= "" THEN
reccompany = Result
Wizard_GetTextBox 3
IF Result ~= "" THEN
rectelephone = Result
Wizard_GetTextBox 4
IF Result ~= "" THEN
recfacsimile = Result
if (buttonresult = 3) THEN
SIGNAL FINISH
/* Step 5 */
STEP5:
WizardReq TITLE "Fax Template Wizard" LABEL "Please type in the name that you would" LABEL "like to give the template:" TEXTBOX 1 "Template N_ame:" CONTENTS deftemplatename BUTTON 1 "_Next" BUTTON 2 "_Previous" BUTTON 3 "_Finish" BUTTON "-1" "_Cancel"
buttonresult = Result
if (buttonresult = -1) THEN
EXIT
if (buttonresult = 2) THEN DO
defrecname = recname
defreccompany = reccompany
defrectelephone = rectelephone
defrecfacsimile = recfacsimile
SIGNAL STEP4
END
/* Get and store results */
Wizard_GetTextBox 1
IF Result ~= "" THEN
templatename = Result
if (buttonresult = 3) THEN
SIGNAL FINISH
/* Finished */
WizardReq TITLE "Fax Template Wizard - Creating" LABEL "The Fax template is finished requesting information from you." LABEL "" LABEL "Click Finish to create your fax template and save it to disk" LABEL "for future use." LABEL "" LABEL "Note: The creation of the fax may take a short while." BUTTON 1 "_Finish" BUTTON 2 "_Previous" BUTTON "-1" "_Cancel"