rbWiki > DADE > Custom Designers

Custom Designers

Table of contents
No headers

Data Designers descend from TdaCustomDataWizard which is defined in daDataWizard.pas.

The TdaCustomDataWizard class defines a class function called DataViewClass that should be overriden by descendants classes to specify the DataView class for which the data designer is implemented.

The daRegisterWizard and daUnRegisterWizard procedures defined in daDataWizard.pas are used to register and unregister Data Designers with DADE.

For an example of a data designer, see daQueryDesigner.pas which contains the default QueryDesigner. The TdaQueryDesigner class overrides the DataViewClass method to return TdaQueryDataView. Therefore, the QueryDesigner is used with any descendant of TdaQueryDataView (TdaADOQueryDataView, TdaBDEQueryDataView, etc.).

For an example of registering a Data Designer, see the initialization and finalization sections of daIDE.pas.

Note: To replace an existing Data Designer, unregister the default designer first:   

initialization
 daUnRegisterWizard(TdaQueryWizard);
 daUnRegisterWizard(TdaQueryDesigner);
  
 daRegisterWizard(TmyCustomQueryWizard);
 daRegisterWizard(TmyCustomQueryDesigner);

finalization
 daUnRegisterWizard(TmyCustomQueryWizard);
 daUnRegisterWizard(TmyCustomQueryDesigner);

     

Tags

Files (0)

 
You must login to post a comment.