I may not have been clear on what I am trying to do. I have a data dictionary which points to a local copy of the tables on my "C" drive. I need to also be able to report for the production tables on a server.
I created the following script (based on your post)
lparameters toApplication, toDatabase
local loDataSource
loDataSource = toDatabase.DataSources.AddItem('VFP', 'My Datasource 1')
loDataSource.Database = 'c:\medstkvfp7\medstkvfp.dbc'
loDataSource = toDatabase.DataSources.AddItem('VFP', 'My Datasource 2')
loDataSource.Database = 'k:\medstkvfp.dbc'
where "K" is drive letter for the mapped folder on the server. I still only see the tables on the "C" drive. What did set "allow multiple data sources" to true. What am I missing?
>Hi Claude.
>
>>I have a test and a production system that use the same database name. I would like to be able to run reports form both of them. I orginally created a project with the test version of the database.
>>
>>How do I add the production database to the project?
>
>Create a GetDataSources script for the database (in the Configuration Utility, select the database node, then click on the Create GetDataSources link). Then fill in some code that adds objects to the DataSources collection, specifying the location of the database. For example:
>
lparameters toApplication, toDatabase
>local loDataSource
>loDataSource = toDatabase.DataSources.AddItem('VFP', 'My Datasource 1')
>loDataSource.Database = 'c:\apps\data1\mydatabase.dbc'
>loDataSource = toDatabase.DataSources.AddItem('VFP', 'My Datasource 2')
>loDataSource.Database = 'c:\apps\data2\mydatabase.dbc'
>Doug