Chapter 8 Extended Model Definitions Reference Guide


Generate for a separate target

Extended model definitions can be used to create new generation targets provided the following conditions are respected:

This generation is called extended generation. It is available from the Tools→Extended Generation command.

If you have several extended model definitions designed for extended generation, these will appear in the Targets page of the extended generation dialog box.


Specific menu command

You can create commands in the Tools menu to directly access extended generation for a selected target. To do so you have to:

Sub %Method%(obj)

   Dim selection ' as ObjectSelection
   
   ' Create a new selection
   set selection = obj.CreateSelection
   
   ' Add object of the active selection in the created selection
   selection.AddActiveSelectionObjects

   ' Generate scripts for specific target
   InteractiveMode = im_Dialog
   obj.GenerateFiles "", selection, "specific target"
   
End Sub

Where "specific target" is used to type the code of the extended generation target. With this parameter, you no longer need to select a generation target for extended generation.

For more information on how to create a method, see section Defining methods in a profile in chapter Managing Profiles.

The new command appears in the Tools menu.


There is no more Targets page because the method lying behind the command already specifies a generation target.

 


Copyright (C) 2005. Sybase Inc. All rights reserved.