AnnGetHyperlinkType example for C++ Builder
//The following is an example of OnAnnHyperlink event code, which includes a call to AnnGetHyperlinkType.
void __fastcall TForm1::LEADAnn1AnnHyperlink (L_HANDLE hObject,
int iParamCount, int lParam1, int lParam2, int lParam3, int lParam4,
int lParam5)
{
AnsiString msgstr;
int nType;
nType= LEADAnn1->AnnGetHyperlinkType (hObject);
if ((nType == ANNLINK_ANNEVENT5) || (nType == ANNLINK_ANNEVENT))
{
if (iParamCount >= 0)
msgstr= IntToStr (iParamCount) + " params are valid" + "\n";
if (iParamCount >= 1)
msgstr= msgstr + "Param1: " + IntToStr (lParam1) + "\n";
if (iParamCount >= 2)
msgstr= msgstr + "Param2: " + IntToStr (lParam2) + "\n";
if (iParamCount >= 3)
msgstr= msgstr + "Param3: " + IntToStr (lParam3) + "\n";
if (iParamCount >= 4)
msgstr= msgstr + "Param4: " + IntToStr (lParam4) + "\n";
if (iParamCount == 5)
msgstr= msgstr + "Param5: " + IntToStr (lParam5) + "\n";
}
else
msgstr= "Invalid Type";
ShowMessage (msgstr);
}