FileName >REPORTS\DailyDetails0001.REP>
ShowProgress >.T.>
Preview
>.T.
>ShowPrintDialog >.F.>
Property >VP_CCLIENTNAME >Venus Software Operations>
Property >VP_DFROMDT >{^20051011}>
Property >VP_DTODT >(^20051011}>
Property >VP_CSYMBOLS >AND cSymbol IN ('INDIABULLS','GOLD','S&P CNX NIFTY',; 'TISCO','RELIANCE','INFOSYS','GHCL','GARDENSILK',; 'HMT','TCS','RELCAPITAL','INFOSYSTCH','HDFCBANK','SATYAMCOMP','WIPRO')>
Property >VP_LSHOWABNORMAL >.F.>
Title >Daily Details>
LPARAMETERS tcCursor > > >wait window "1 " + tcCursor > >LOCAL loForm > > >SET CLASSLIB TO cReportManager.vcx ADDITIVE > > >loForm = CREATEOBJECT("cfrmReportManager") > > >wait window "2 " + tcCursor >USE (tcCursor) AGAIN >wait window "3 " + tcCursor > >SCAN > wait window prpty >ENDSCAN > >wait window "4 " + tcCursor >USE >wait window "5 " + tcCursor > > >loForm.RELEASE() > > >*QUITBhavbhuti,
ldDate = date() lnNumber = 123 lcName = 'Bhavbhuti' lcBridge = sys(2015)+'.prg' set textmerge to (m.lcBridge) noshow set textmerge on \\lparameters toObj \with toObj \ .Prop1 = {^<<transform(dtoc(m.ldDate,1),'@R 9999/99/99')>>} \ .Prop2 = <<m.lnNumber>> \ .Prop3 = '<<m.lcName>>' \endwith set textmerge to set textmerge off *Receiver get m.lcBridge - name of file to read Compile (m.tcBridge) do (m.tcBridge) with myObject erase (forceext(m.tcBridge,'*'))You can use now forgotten feature of Foxpro's ability to save and restore memory variables to .mem files. ie:
clear all clear local lcPackageName lcPackageName = 'myParms.mem' PackageParms(m.lcPackageName) lcSomeVar = "created in between" RestoreParms(m.lcPackageName) erase (m.lcPackageName) Function RestoreParms && receiver lparameters tcPackageName restore from (m.tcPackageName) additive disp memo like lc* * Note that these are local as they're declared in saving routine disp memo like _p* endfunc Function PackageParms && Sender lparameters tcPackageName local _pMyDate, _pMyDateTime, _pMyChar, _pMyNum, _pMyExpr local array _paCollection[4,2] _pMyDate = date() _pMyDateTime = datetime() _pMyChar = 'character' _pMyNum = 12345 _pMyExpr = 'and Something in ("v1","v2")' _paCollection[1,1] = 'Name' _paCollection[2,1] = 'Children' _paCollection[3,1] = 'BirthDate' _paCollection[4,1] = 'Hobbies' _paCollection[1,2] = 'Smith' _paCollection[2,2] = 3 _paCollection[3,2] = {^1957/03/27} _paCollection[4,2] = replicate("some hobby",500) save to (m.tcPackageName) all like _p* endfuncYou can pass Name,Value pairs as string which receiving side assigns with eval(). ie: