AnnAutomation example for C++ Builder

This example shows how you can use the AnnAutomation property to access the automation object through DLL functions.

L_BOOL IsBold; // Is the object's text bold
int hAnnObject;

hAnnObject= LEADAnn1->AnnAutomation;
//Set the default font to bold, unless it already isL_AnnGetFontBold ( hAnnObject, &IsBold ) ;
if (IsBold != 0 )
    ShowMessage ("Already bold");
else
    L_AnnSetFontBold  (hAnnObject, 1, 0);