Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
HELP: Can't Select from table included in project.
Message
From
22/11/2000 09:37:04
 
 
To
22/11/2000 07:43:15
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Miscellaneous
Thread ID:
00444441
Message ID:
00444586
Views:
9
Jens,

I tried your work around but ended up with the same results. I opened the table with alias "test" in testapp1 and then selected from test in testapp2, but received the same error message: "File "testtable.dbf" does not exist".

As my response to Walter notes, including all the tables in the first app is not a realistic solution in my case, since in would make the main exe excessively large (>284MB) and more difficult to update.

I'm curious how did you get the alias change to work?

>Timothy,
>
>This is a strange one. I get the same results as you, but if I open the table with alias "test" in testapp1 and then select from test in testapp2, everything works fine. Maybe the table has to have an alias different from the tablename?
>
>I've had the same problems in converted apps, where included and opened tables weren't available in other apps. I didn't find other solution than to include the table inn the second app too, and then check for !USED() in the second app and reopen this included table if not used. Not a very good solution, but it seems to work.
>
>Please let me know if you find an answer.
>
>Jens Erik
>
>
>>We are converting a 2.6 app to VFP 6.0 and I've noticed a change in how foxpro handles included tables. In 2.6, if you included a table in a project file, once the table was opened, it could be included in any select statement. However, this ceased being the case in VFP. Now, the select statement seems to need the original file, even though it is open, browsable, etc.
>>
>>Anybody have any idea what's happening here or how to work around the problem?
>>
>>If you want to reproduce the problem, here are the steps:
>>
>>
>>steps to recreate:
>>
>>create table testtable (testfield c(5))
>>insert into testtable values ('a123')
>>insert into testtable values ('b123')
>>insert into testtable values ('c123')
>>insert into testtable values ('d123')
>>insert into testtable values ('e123')
>>
>>create proj testproj
>>
>>* add testtable as free table and mark as included
>>* add following procedure and mark as main
>>
>>Procedure testprog
>>close all
>>use testtable
>>
>>create proj testproj2
>>
>>* add following procedure and mark as main
>>
>>procedure testprog2
>>do testproj.app
>>brow nowait
>>select * from testtable
>>
>>build both projects as application (app)
>>delete or move the file testtable.dbf (it's now part of the app)
>>
>>try to run testproj2.app.  The table will open.  You can browse it, but you can't select from it.
>>
>>
Timothy D. Yeaney
MCSD, Charter Member
President, PAFOX (Potomac Area Fox User Group)
mailto:tim@eagleeyeinc.com
Vice President
Eagle Eye Publishers, Inc
Broaden Your Vision, Sharpen Your Focus
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform