Skip to content

Settings

Radu Martin edited this page Apr 15, 2017 · 5 revisions

This class is used for setting up parameters. These parameters have default values and their additional configuration is not required.

Setting the main from

The method SetMainForm indicates the main application form. It is used for showing in dialogues and SelectItemForm.

Images

Images indicates the two images that are used in TableLayoutPanel. SelectRowImage points the Bitmap image which is used in the drop-down list. ClearFieldImage points the Bitmap image which is used to clear the existing value for fields that can be NULL.

HeaderTableLayoutPanel

Two setting are for describe HeaderTableLayoutPanel parameters during generation: CaptionStyle of CBComponents.HeaderTableLayoutPanel.HighlightCaptionStyle type CaptionLineWidth of byte

Example of using

public MainForm()
{
  CBComponents.Settings.SetMainForm(this);

  CBComponents.Settings.Images.SelectRowImage = image1;
  CBComponents.Settings.Images.ClearFieldImage = image2;

  CBComponents.Settings.HeaderTableLayoutPanel.CaptionLineWidth = 2;
  CBComponents.Settings.HeaderTableLayoutPanel.CaptionStyle =
      HeaderTableLayoutPanel.HighlightCaptionStyle.NavisionAxaptaStyle;
  
  InitializeComponent();
  ...
}