Xpounded brings you the CheezWiz Wizard.
I've chosen to write the implementation in VBS limiting its operation to Explorer enviornments
CheezWiz is a cool idea designd to easily implement code reuse where you have
many variants on a base code.
A simple example would be the div statement. Let's say that when you make a div you usually use the color and background style
properties, but you wind up altering their values according to your needs.
With CheezWiz, you write the code just once, and from then on, you use the CheezWiz Wizard to
create your code for you.
Algorithm Key:
The key to the algorithm is specified delimiters. I've chosen brackets as the delimiters.
bracketed values will act like variables, the brackets along with the content in the brackets act as the
variable name.
These bracketed values are used in a multi-line string that the CheezeWiz will parse.
When CheezWiz parses such a string, it replaces all occurance of the bracketed value with a
new value the user provides via an inputbox.
USE:
You have to feed the CheezeWiz Algoritm a specifically formatted string that it will parse, createing your simple wizard.
Requirements
Bracket variables always come first in the parse string.
You can place a default value immediately after a bracket variable.
Place the bracket variable at the point in the string you want to use it.
(The string refered to is a multi-line string)
The example below should clear this up a bit - try it out!
(You can try writting your own wiz here. Just match up the bracket variables)
Try It!
Source for the CheezeWiz
The CheezWiz Result
This small div example only hints at the use of the CheezeWiz. It really comes into its own
when you start designing more complex structures and code segments.
- Copyright 2003-2006 Xpounded -
All JS code developed by Xpounded is developed in RHSCoder.
All VBS code developed by Xpounded is developed in VBS QuickDev IDE, or RHSCoder. Feedback