My notes about MyGeneration Templates

I’ve started to use MyGeneration  templates. They are very powerful and easy to customize. However I feel it is not always easy to find documentation.It is split between different sites and also not searchable by Google(see discussions here and here).So I decided to put  here the links that are useful for me .

The introductiontoMyGeneration can be found in articles on CodeProject and

MyGeneration allows to write scripts in VBScript,JScript, C# and VB.Net. In DotNetScript UI can be written using use the standard .Net windows forms and propriatory Zeus input form. I prefer to use C# DotNetScript with using WinForms -and the authors of EntitySpaces use the same in their ASP.NET templates. However many of the old templates in the Template Library are written using other languages, which makes it a little bit harder to copy and paste code snippets. 

There is set of articles in TemplateLibrary.
For me the most useful are Developing DotNetScript Templates – MyGeneration  and MyGeneration Project Files.
(don’t waste your time to open articles, authored by lmterra  – they currently refer to dead links).

In forums site there is Tips and Tricks forum with Include Files in MyGeneration, , Your First MyGeneration Plug-In and SubTemplate Execution  tips.

The procedure of debugging is described here and in the help  . However I found it is required some tricks to show source – see Debug in VS2005 thread.

To  create easier UI for templates see in dOOdads ASP.NET Inline Grid archive and in particular comment at the end of the post from  my.generation :

I added the project that I used to create the UI to the archive. It’s called MyMeta wont run unless you call the application MyGeneration, thus the name. Anyway, notice the use of the variable “input” which is a hash table, when I copy this code in the UI I only copy the code from MyForm_Load() on down. It makes for an extremely fast way to write/debug full winform UI’s. Just change the connection string in the Main() function where it creates and initializes a MyMeta object.

See also discussion Creating the GUI part of the template in Visual Studio

Alternative approach to creating UI in searate DLL shown in archive:Embedding Windows Forms in the Template UI .
Not sure, does Syntax-colouring plug-in for MyGeneration UI add any value,or current implementation sufficient.

Environment variables for template from Zeus API Reference Zeus.ZeusInput . The current template script metadata are accessible through  IZeusTemplateStub class.The sample to get them (e.g. Template Title) is shown here

To output ASP.NET dynamic tags <% and %> from templates see post .

I’ve posted template: Ajax Auto Complete WebServices using EntitySpaces