January 18, 2019
Hot Topics:

Concrete Code for a Quick Configuration

  • October 25, 2005
  • By Robert Bogue
  • Send Email »
  • More Articles »

The Non-Configuration Solution

Now that you've seen the code, it's time to evaluate how complicated this would be to implement as if/then statements. For the example file I gave, there are only 7 if statements that would be necessary. It's probably shorter to hard code the questions into the body of the program - however; the true power of this questionnaire solution is that it can be used with any questionnaire containing any number of questions.

If there are 500 questions in the database - the code remains the same code that you've seen here. This code is much less complicated and much easier to maintain than 500 if statements.

In Conclusion

What makes this solution configuration based is its ability to create new solutions based on a different configuration (or input) file. This is incredibly powerful when applied to your day-to-day programming tasks.


Questionnaire.zip - Source code for questionnaire with question configuration.

About the Author

Robert Bogue, MCSE (NT4/W2K), MCSA:Security, A+, Network+, Server+, I-Net+, IT Project+, E-Biz+, CDIA+ has contributed to more than 100 book projects and numerous other publishing projects. He was recently honored to become a Microsoft MVP for Microsoft Commerce Server and before that Microsoft Windows Servers-Networking. Robert blogs at http://www.thorprojects.com/blog. You can reach Robert at Rob.Bogue@thorprojects.com.

Page 2 of 2

Comment and Contribute


(Maximum characters: 1200). You have characters left.



Enterprise Development Update

Don't miss an article. Subscribe to our newsletter below.

Thanks for your registration, follow us on our social networks to keep up-to-date