Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

DBCMD/2001 Work area not in use

556 views
Skip to first unread message

Lucas

unread,
Sep 30, 2012, 4:10:00 PM9/30/12
to
Hi,

Some customers have reported me such error in line 5 from time to time:


1) local pPATH := hb_DIRBASE()

[...]

2) lFichero := pPATH+"DATOS\TEST" + alltrim( str( nEmisor ) ) + ".DBF"
3) lIndice := pPATH+"DATOS\TEST" + alltrim( str( nEmisor ) ) + ".CDX"

4) SELECT 10
5) USE &lFichero INDEX &lIndice ALIAS TESTDBF SHARED NEW


function hb_DIRBASE()
return cFilePath( GetModuleFileName( GetInstance() ) )


Before I check the file.

I have not been able to reproduce the error in my PC.

Please, do you have any tip?.

Thank you very much!!.



Lucas

unread,
Sep 30, 2012, 4:12:16 PM9/30/12
to
I forgot to tell that if happens mostly in Windows Vista or 7.

I use BCC 5.82 too.

dlzc

unread,
Sep 30, 2012, 7:34:39 PM9/30/12
to
Dear Lucas:

On Sunday, September 30, 2012 1:10:00 PM UTC-7, Lucas wrote:
...
> Some customers have reported me such error
> in line 5 from time to time:
>
>
> 1) local pPATH := hb_DIRBASE()
>
> [...]

Any chance pPATH has been released, or is out-of-scope?

> 2) lFichero := pPATH+"DATOS\TEST" + ;
> alltrim( str( nEmisor ) ) + ".DBF"
>
> 3) lIndice := pPATH+"DATOS\TEST" + ;
> alltrim( str( nEmisor ) ) + ".CDX"

Any chance lFichero or lIndice have been released, or are out-of-scope?

> 4) SELECT 10

Why do you do this, when you use the new keyword below?

> 5) USE &lFichero INDEX &lIndice ALIAS TESTDBF SHARED NEW

Any chance the alias TESTDBF is already in use?

> function hb_DIRBASE()
>
> return cFilePath( GetModuleFileName( GetInstance() ) )
...
> Please, do you have any tip?.

Did you have them send you error.log? Did you resize the screen, so that the entire error message is displayed?

David A. Smith

cher...@gmail.com

unread,
Sep 30, 2012, 11:26:46 PM9/30/12
to
Lucas
Where are you getting cFilePath(),GetModuleFileName() and GetInstance() from?
Regards
Claudio H

Lucas

unread,
Oct 1, 2012, 3:37:09 AM10/1/12
to
Dear David:

Thanks for reply.

> Any chance pPATH has been released, or is out-of-scope?
>

No, the path is ok. I checked previously and it is ok.

In my PC the code wors always fine.

>
>
> > 2) lFichero := pPATH+"DATOS\TEST" + ;
>
> > alltrim( str( nEmisor ) ) + ".DBF"
>
> >
>
> > 3) lIndice := pPATH+"DATOS\TEST" + ;
>
> > alltrim( str( nEmisor ) ) + ".CDX"
>
>
>
> Any chance lFichero or lIndice have been released, or are out-of-scope?
>

No, they are checked before in a previous step.

>
> > 4) SELECT 10
>
>
>
> Why do you do this, when you use the new keyword below?
>
>

I am going to remove it. That´s how I did in Clipper:

select 1
use xxx new shared alias xxx

>
> > 5) USE &lFichero INDEX &lIndice ALIAS TESTDBF SHARED NEW
>
>
>
> Any chance the alias TESTDBF is already in use?
>
>

No, and I opened it in shared mode.

>
> Did you have them send you error.log? Did you resize the screen, so that the entire error message is displayed?


I can´t see screen. But I discovered that the error happens when the user changes setup path at the installer to c:\Program Files instead of c:\mysoftware.com which is the default path.

Maybe it is a question of Windows special features or requirements of c:\program files folder?.

Thank you again.

Best regards,

dlzc

unread,
Oct 1, 2012, 10:55:39 AM10/1/12
to
Dear Lucas:

On Monday, October 1, 2012 12:37:10 AM UTC-7, Lucas wrote:
...
> > > 4) SELECT 10
>
> > Why do you do this, when you use the new
> > keyword below?
>
> I am going to remove it. That´s how I did in Clipper:
>
> select 1
>
> use xxx new shared alias xxx

OK.

...
> > Any chance the alias TESTDBF is already in use?
>
> No, and I opened it in shared mode.

OK. My concern was that the alias was already in use.

> > Did you have them send you error.log?
> > Did you resize the screen, so that the
> > entire error message is displayed?
>
> I can´t see screen. But I discovered that the
> error happens when the user changes setup path
> at the installer to c:\Program Files instead
> of c:\mysoftware.com which is the default path.

Both of these are against Micro$haft's accepted practice, when you try and work with DBFs in the same directory. So...

> Maybe it is a question of Windows special
> features or requirements of c:\program files
> folder?.

I would guess that these target computers are also Vi$ta or Win7. Micro$haft wants all your dbfs to be in USERS\<cUserName>\"whatever after that" (or a mapped drive), and not "anywhere you feel like" off the root drive.

Sorry.

David A. Smith
0 new messages