A code gen utility that creates C# objects out of SWEA controls

Tod Birdsall has created an online SWEA .htp parser that will take your .htp file and break each scene’s controls down into C# objects. In the past this is something I did by hand, but I thought it could be useful to you if you’re just putting your framework together or are refactoring. Pretty handy when you have a few hundred controls. The utility will take this:

        <Control Name=”Nav_Users” Type=”HtmlAnchor”>
            <HtmlName />
            <TagName />

and turn it into this:

// ParentName = sceneChallengeReport
HtmlAnchor Nav_Users = ((HtmlAnchor)browser.Scene[“Nav_Users”]);

The code gen utility can be found here.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.