Hi again,
a new test confirms your problem. But why do you need to open both the .prg and the .bak at the same time? Over the more than 30 years I have programmed, I have never needed to do that, but I have a lot of duplicated code in different temp directories.
>>I can NOT copy this, Fabio, everything works as expected. Have you marked "Make backup" in Tools-options-IDE? I have.
>
>Of course ! Otherwise, who creates the .bak ?
>
>>
>>>VFP 9 can write large prg files.
>>>Now, because, at the same time, i cannot open two or more program.prg edit windows,
>>>i try this:
>>>open the program.bak in read mode, and edit program.prg.
>>>One ugly surprise:
>>>when i save (only save!!!) VFP says to me:
>>>-
File access is denied (Error 1705)>>>and
>>>-
close the edit window, losing all my modifications !!>>>
>>>To use VFP within a Dev Team ?
>>>Example:
>>>
>>>- Dev1 open a .prg
>>>- Dev2 cannot open .prg
>>>- then Dev2 open the .bak
>>>- Dev1 works for 2 hours
>>>- Dev1 a coffee wants drink,
>>> then it press Save
>>>- Dev1 the coffee does not drink more,
>>> but one is drunk camomile!
>>>
>>>
>>>An optimal way in order to pass the days!
>>>
>>>Ask: why VFP open a prg in pessimistic lock mode ?
>>>Expected:
>>>
>>>- Open a .prg
>>>- At first edit operation:
>>>a) refresh the file with a write lock access
>>>
>>>b) when save, if a error occurs, NOT CLOSE THE MODIFY WINDOW !!!!!!!!!
>>>
>>>
>>>Another point:
>>>the situation is still worse than how much it seems.
>>>If you uses:
>>>
>>>MODIFY COMMAND SOMEPROGRAM.BAK NOEDIT
>>>
>>>VFP open SOMEPROGRAM.BAK with a write exclusive access !,
>>>and you still must to drink camomile.
>>>
>>>Fabio