Page 1 of 1

Add StiComboBox to StiPreviewControl-toolbar

Posted: Wed Jul 05, 2006 3:36 am
by scotty
Is it possible to add a comboBox to the toolbar of the StiPreviewControl?

How do I set the items for the ComboBox?

How can I find out, that the SelectedItem of the ComboBox is changed?

thanks
scotty

Add StiComboBox to StiPreviewControl-toolbar

Posted: Wed Jul 05, 2006 3:57 am
by Vital

You can do it with PreviewControl. This control have field - tbTool. This is toolbar.
To add ComboBox you can use this code:

Code: Select all

ComboBox comboBox = new ComboBox();
comboBox.Dock = DockStyle.Left;
comboBox.Items.Add("1");
comboBox.Items.Add("2");
comboBox.Items.Add("3");
previewControl1.tbTool.Controls.Add(comboBox)

Thanks.