>>We have code that opens database. We were testing DBC(). Prior to the command SET DATABASE TO mmVisCollect the DBC() functions returned T:\IT_Testing\Data\MMVisCollect.DBC Right after that statement DBC() returned c:\MMVisCollect\Data\MMVisCollect.DBC. In other words, SET DATABASE TO myDatabaseName caused the local database to be used instead of the network database.
>>
>>I'm going to post another thread in MereMortals category, because this is a very dangerous problem and situation for us.
>>
>
>I don't think that set database is one causing the problem.
>Ususaly it is old known bug with form DE being 'responsible' for those erroneous table openings. Or it can be that VFP openning first DBC with the same name found in path, when you don't specify full path.
>
>
>if you directly open database with full path
>and then tables contained in them like ;
>
>
>local cMyDatabase
>cMyDatabase = '\\server\data\myDataBase.dbc'
>open database (cMyDatabase)
>set database to (cMyDatabase)
>use myTable in 0 shared ...
>.
>.
>
>You will never hv a problem.
>
>To fix problem with form DE cursor objects opening whatever is preset in their database property, you have to apply some code in DE.BeforeOpenTables changing their database path to one you realy want to open.
>
>I posted solution for this meny times here in the past
>and Cetin also have one. If you don't find it here in messages,
>let me know, I will sent you one directly via email.
>
>Now in MM context I don't know what to tell you ...
>You hv to ask them.
>
>Rgds++
>Sergio
I was hoping that MereMortals handles this problem automatically. That's why I posted another question in that category hoping that some MM users can test it. I just need to find out if it's something pecuiliar to our environment or it can be reproduced by other MM users as well.
If it's not broken, fix it until it is.
My Blog