I have to run multiple instances of an app on the same desktop. I thought I
could use rlock() on a shared table so each instance would know what data it
can't process.... but, although I seem to remember doing this successfully
many years ago, it doesn't seem to work any more. My work around, testing
for the ability to fcreate() a flag file works fine.
What's up with rlock(), vfp9 & xp?
--
-Lew
The workers took the robot for Maria.

Re: rlock() & multiple instances of app by Fred

Fred
Tue Jan 09 23:20:06 CST 2007

Nothing's wrong with RLOCK(), it works just fine with XP.

--
Fred
Microsoft Visual FoxPro MVP


"Lew" <lew@fastmail.fm> wrote in message
news:eAX0XOHNHHA.4888@TK2MSFTNGP02.phx.gbl...
>I have to run multiple instances of an app on the same desktop. I thought I
>could use rlock() on a shared table so each instance would know what data
>it can't process.... but, although I seem to remember doing this
>successfully many years ago, it doesn't seem to work any more. My work
>around, testing for the ability to fcreate() a flag file works fine.
> What's up with rlock(), vfp9 & xp?
> --
> -Lew
> The workers took the robot for Maria.
>



Re: rlock() & multiple instances of app by Man-wai

Man-wai
Wed Jan 10 00:02:37 CST 2007

> can't process.... but, although I seem to remember doing this successfully
> many years ago, it doesn't seem to work any more. My work around, testing
> for the ability to fcreate() a flag file works fine.
> What's up with rlock(), vfp9 & xp?

What error did you get?

--
iTech Consulting Co., Ltd.
Specialized in providing ePOS solutions
Website: http://www.itech.com.hk (IE only)
Tel: (852) 2325 3883 Fax: (852)2325 8288

Re: rlock() & multiple instances of app by Carsten

Carsten
Wed Jan 10 06:03:00 CST 2007

Lew,

it more looks like you leave the record you are locking. If MULTILOCKS is
OFF, the lock is automatically released.

--
Cheers
Carsten
_______________________________

"Lew" <lew@fastmail.fm> schrieb im Newsbeitrag
news:eAX0XOHNHHA.4888@TK2MSFTNGP02.phx.gbl...
>I have to run multiple instances of an app on the same desktop. I thought I
>could use rlock() on a shared table so each instance would know what data
>it can't process.... but, although I seem to remember doing this
>successfully many years ago, it doesn't seem to work any more. My work
>around, testing for the ability to fcreate() a flag file works fine.
> What's up with rlock(), vfp9 & xp?
> --
> -Lew
> The workers took the robot for Maria.
>



Re: rlock() & multiple instances of app by Lew

Lew
Wed Jan 10 06:38:52 CST 2007

No error, all instances ignore the rlock & start processing the same data.

"Man-wai Chang" <toylet.toylet@gmail.com> wrote in message
news:OruWpzHNHHA.3668@TK2MSFTNGP02.phx.gbl...
>> can't process.... but, although I seem to remember doing this
>> successfully many years ago, it doesn't seem to work any more. My work
>> around, testing for the ability to fcreate() a flag file works fine.
>> What's up with rlock(), vfp9 & xp?
>
> What error did you get?
>
> --
> iTech Consulting Co., Ltd.
> Specialized in providing ePOS solutions
> Website: http://www.itech.com.hk (IE only)
> Tel: (852) 2325 3883 Fax: (852)2325 8288



Re: rlock() & multiple instances of app by Lew

Lew
Wed Jan 10 06:41:01 CST 2007

No, there's no reason for the app to look at another rec until & unless it's
done processing the data. However, both the workarea and datasession change
frequently. I'll look into this.
-Lew
"Carsten Bonde" <bonde AT real-inkasso DOT de> wrote in message
news:eZUMe9KNHHA.4384@TK2MSFTNGP03.phx.gbl...
> Lew,
>
> it more looks like you leave the record you are locking. If MULTILOCKS is
> OFF, the lock is automatically released.
>
> --
> Cheers
> Carsten
> _______________________________
>
> "Lew" <lew@fastmail.fm> schrieb im Newsbeitrag
> news:eAX0XOHNHHA.4888@TK2MSFTNGP02.phx.gbl...
>>I have to run multiple instances of an app on the same desktop. I thought
>>I could use rlock() on a shared table so each instance would know what
>>data it can't process.... but, although I seem to remember doing this
>>successfully many years ago, it doesn't seem to work any more. My work
>>around, testing for the ability to fcreate() a flag file works fine.
>> What's up with rlock(), vfp9 & xp?
>> --
>> -Lew
>> The workers took the robot for Maria.
>>
>
>



Re: rlock() & multiple instances of app by Man-wai

Man-wai
Wed Jan 10 08:09:16 CST 2007

> No error, all instances ignore the rlock & start processing the same data.

Are you sure that there is really a contention? What if you SET
EXCLUSIVE ON?

--
.~. Might, Courage, Vision, SINCERITY. http://www.linux-sxs.org
/ v \ Simplicity is Beauty! May the Force and Farce be with you!
/( _ )\ (Ubuntu 6.10) Linux 2.6.19.1
^ ^ 22:08:01 up 29 days 4:20 0 users load average: 1.03 1.03 1.00
news://news.3home.net news://news.hkpcug.org news://news.newsgroup.com.hk

Re: rlock() & multiple instances of app by Lew

Lew
Wed Jan 10 09:14:08 CST 2007

Yep, it's contention. If I set exclusive on, all instances except the first
produce nothing but errors.

"Man-wai Chang" <toylet.toylet@gmail.com> wrote in message
news:eiSFnDMNHHA.4172@TK2MSFTNGP03.phx.gbl...
>> No error, all instances ignore the rlock & start processing the same
>> data.
>
> Are you sure that there is really a contention? What if you SET
> EXCLUSIVE ON?
>
> --
> .~. Might, Courage, Vision, SINCERITY. http://www.linux-sxs.org
> / v \ Simplicity is Beauty! May the Force and Farce be with you!
> /( _ )\ (Ubuntu 6.10) Linux 2.6.19.1
> ^ ^ 22:08:01 up 29 days 4:20 0 users load average: 1.03 1.03 1.00
> news://news.3home.net news://news.hkpcug.org news://news.newsgroup.com.hk



Re: rlock() & multiple instances of app by Man-wai

Man-wai
Thu Jan 11 01:13:39 CST 2007

Lew wrote:
> No, there's no reason for the app to look at another rec until & unless it's
> done processing the data. However, both the workarea and datasession change
> frequently. I'll look into this.

Sounds like each instance is RLOCKing different part of the DBF....

--
iTech Consulting Co., Ltd.
Specialized in providing ePOS solutions
Website: http://www.itech.com.hk (IE only)
Tel: (852) 2325 3883 Fax: (852)2325 8288