Page 1 of 1

TeeInspector, Selections

Posted: Fri Jul 06, 2007 6:24 pm
by 9341114
Can anyone direct me to some example code on how to set up a Selection in the TeeInspector component?

Thanks

Paul

Posted: Fri Jul 06, 2007 8:05 pm
by narcis
Hi Paul,

Have you seen the example at All Features\Welcome!\Components\Inspector component in the features demo? You'll find the features demo at TeeChart's program group created by the binary installers. Source code installer doesn't include any example nor documentation.

Posted: Fri Jul 06, 2007 8:51 pm
by 9341114
Narcis -

Maybe I should have mentioned that I've already checked the features demo. Unfortunately, the demo code does not include implementation of a Selection. Is there someplace else I can look?

Thanks

Paul

Using TeeInspector, creating items at runtime

Posted: Thu Jul 12, 2007 2:14 pm
by 9341114
Can anyone help with information on using TeeInspector? The example code on "all features" gives no hints for programming with this component. I need to create items at run time, as well as populate the selections.

Thanks

Paul

Posted: Fri Jul 13, 2007 9:17 am
by Pep
Hi Paul,

I think the better example code to check and review which could help you is the TeeChartOffice demo sources, it uses most of the characteristics of TeeInspector.

Posted: Fri Jul 13, 2007 1:50 pm
by 9341114
Thanks - but unfortunately that code doesn't help much either as far as setting up items at run time. All it does is:

Inspector.SetProperties(DBChart1.PopupMenu);

I'm trying to set up properties indendant of any chart, and I don't have TeeInspector.pas which is where this method is located.

I've got some working by trial and error, but I'm sure I'm missing a lot.

Paul

Posted: Mon Jul 16, 2007 6:38 am
by Pep
Hi Paul,

ok, no worries. I'm not sure what you're trying to do but if you just want to add some options and check the selection you can use similar code to the following :

Code: Select all

procedure TForm1.GetTestItems(Sender:TInspectorItem; Proc:TGetItemProc);
begin
  Proc('One');
  Proc('Two');
  Proc('Three');
end;

procedure TForm1.FormCreate(Sender: TObject);
var Item : TInspectorItem;
begin
  TeeInspector1.Clear;
  Item:=TeeInspector1.Items.Add(iiSelection,'Test',nil);
  Item.OnGetItems:=GetTestItems;
  Item.Value:='Two';
end;