>>#INCLUDE HOME()+ "VFPSOURCE\REPORTOUTPUT\FOXPRO_REPORTING.H" >>#INCLUDE HOME()+ "VFPSOURCE\REPORTOUTPUT\REPORTLISTENERS.H" >>#INCLUDE HOME()+ "VFPSOURCE\REPORTOUTPUT\REPORTLISTENERS_LOCS.H" >>#INCLUDE HOME()+ "VFPSOURCE\REPORTOUTPUT\_FRXCURSOR.H" >> >> >>_reportoutput='reportoutput.app' >>SET ENGINEBEHAVIOR 90 >>SET CLASSLIB TO HOME()+ "ffc\_reportlistener" additive >>SET PROCEDURE TO c:\common30\hyperlinklistener.prg additive >> >>ON ERROR >> >> >>*-- works on dev machine, produces no error on testing machine >>loListener = newobject('HyperlinkListener', ; >> 'HyperlinkListener.prg') >> >>*-- displays 'O' on dev and 'L' on testing machine >>WAIT window TYPE('lolistener') >>>>
>>define class HyperlinkListener as HTMLListener ; >> of home() + 'ffc\_ReportListener.vcx' >> QuietMode = .T. >> && default QuietMode to suppress feedback >> dimension aRecords[1] >> && an array of information for each record in the FRX >> >>* Before we run the report, go through the FRX and store information about any >>* field with our expected directive in its USER memo into the aRecords array. >> >> function BeforeReport >> dodefault() >> with This >> .SetFRXDataSession() >> dimension .aRecords[reccount()] >> scan for atc('*:URL', USER) > 0 >> .aRecords[recno()] = alltrim(strextract(USER, '*:URL =', ; >> chr(13), 1, 3)) >> endscan for atc('*:URL', USER) > 0 >> .ResetDataSession() >> endwith >> endfunc >> >>* If the current field has a directive, add the URL to the attributes for the >>* node. >> >> function GetRawFormattingInfo(tnLeft, tnTop, tnWidth, tnHeight, ; >> tnObjectContinuationType) >> local lcInfo, ; >> lnURL >> with This >> lcInfo = dodefault(tnLeft, tnTop, tnWidth, tnHeight, ; >> tnObjectContinuationType) >> lcURL = .aRecords[recno('FRX')] >> if not empty(lcURL) >> .SetCurrentDataSession() >> lcInfo = lcInfo + ' href="' + textmerge(lcURL) + '"' >> .ResetDataSession() >> endif not empty(lcURL) >> endwith >> return lcInfo >> endfunc >>enddefine >>>>
foxpro_reporting.h >>>reportlisteners.h >>>reportlisteners_locs.h >>>_frxcursor.h >>>>>>