AnnGetTopContainer example for C++ Builder
void TForm1::AnnTestTopContainer()
{
HANNOBJECT hPin;
HANNOBJECT h1;
HANNOBJECT h2;
HANNOBJECT hContainer;
hContainer= LEADAnn1->AnnCreate(ANNOBJECT_CONTAINER,
true, false);
if(hContainer != 0)
{
hPin= 0;
LEADAnn1->AnnCreateItem(hContainer,
ANNOBJECT_PUSHPIN, false, hPin);
LEADAnn1->AnnGetContainer(hContainer,
h1);
LEADAnn1->AnnGetTopContainer(hPin,
h2);
if((h1 == h2) && (h1 == LEADAnn1->AnnContainer))
ShowMessage("root
container is same as that of LEADAnn1");
}
}