Assuming that you have the path to the DBC you want to use specified in an app object, put something like this in the report's dataenvironment.beforeopentables method (works for labels and forms too!):
*** Make sure set deleted is on SET DELETED ON *** Change the hard-coded DBC/cursorsource path in the form's dataenvironment SET CONSOLE OFF
IF TYPE('goApp') = 'O' AND TYPE('goApp.gcDBCPath') = 'C' PRIVATE nObjects, cDir, ni, oObject, aObjects, cTable, cDatabase
nObjects = AMEMBERS(aObjects,This,2) cDir = goApp.gcDBCPath && path to DBC, stored in app object
FOR m.ni = 1 TO nObjects oObject = EVALUATE('This.'+aObjects[ni]) IF UPPER(oObject.Baseclass) = 'CURSOR' && only process cursors cDatabase = oObject.Database IF EMPTY(cDatabase) && free table cTable = oObject.Cursorsource oObject.Cursorsource = cDir + SUBSTR(cTable,RAT('\',cTable)) ELSE && in a DBC oObject.Database = cDir + SUBSTR(cDatabase,RAT('\',cDatabase)) ENDIF ENDIF ENDFOR ENDIF
============ Brian Abbott
ACA Systems ============
> -----Original Message----- > From: profox-bounces .at. leafe D.OT com > [mailto:profox-bounces@leafe.com] On Behalf Of Pablo Velazco > Sent: Wednesday, November 26, 2003 4:36 PM > To: ProFox Email List > Subject: Free reports and labels > > > Hello group, > > I need to re-use many reports and labels, in another system. > They have references to a DBC container how may I delete > those references efficiently? > > TIA, > > Pablo Sebastian Velazco > Dpto.Sistemas Moretti > > > [excessive quoting removed by server]
©2003 Brian Abbott |