Multiple Application Instances Opening same local db file

Ernesto Giannotta erne at apimac.com
Sun Feb 27 11:02:33 CST 2011


Hi Ruslan,

On 25-feb-2011, at 01:25, Ruslan Zasukhin wrote:

> On 2/25/11 12:38 AM, "Chris Jones" <cjones at daz3d.com> wrote:
> 
> Hi Chris, 
> 
>> Is there a way to tell the file has already been open?
> 
> On linux exists   technique of lock file.
> 
> 
> YOUR family of apps, can follow to rule
> That app check for my_db.lck file
> If not found then it can open it and create such lock file.
> 
> All others will see lock file and not touch db.
> 
> 
> E.g. Archicad do this on WIN and MAC ...
> 

in Cocoa when I try to open an already open DB Vale gracefully throws an NSException whose name is:

	File "Untitled Notes.notepad" cannot be opened because it is used by another application.

How does she know?

BTW why you set the name and not the reason with this info?




Cool Runnings,
Erne.



More information about the Valentina mailing list