Page 1 of 1

Where are the files created?

PostPosted: Sun May 23, 2010 7:38 am
by Ross_ValuSoft
Hi all,

I have just returned to using FWPPC after a looong absence.

By way of refreshing my old brain, I have built a few samples including one called "pawel.prg" which creates a dbf file named test with 30000 records. The application was run under the emulator and produced the file shown in the image below. I would like to examine it outside of the emulator's "world", but I cannot find it anywhere on the PC.

Where does the emulator write such files. I have a directory called "C:\pocketpc" which is shared with the emulator and where the newly created .exe applications are stored for use ... but no files.

Thanks,

Ross



Image

Re: Where are the files created?

PostPosted: Wed May 26, 2010 3:42 pm
by Antonio Linares
Ross,

The files are created in the root folder (there is no drive "C:") of the Windows Mobile unless CurDir() is used.

You have to modify these lines in FWPPC\samples\pawel.prg to get the files in the shared folder:
Code: Select all  Expand view

   FErase ( CurDir() + "\Test" + IndexExt() )
   ...
   DbCreate( CurDir() + "\Test", aStr )
   USE ( CurDir() + "\Test" ) NEW
   ...
   INDEX ON F1 + F2 Tag T1 TO ( CurDir() + "\Test" )
   INDEX ON Field->F5 + Field->F1 + Field->F2 Tag T2 TO ( CurDir() + "\Test" )
   INDEX ON Field->F4 + Field->F1 + Field->F2 Tag T3 TO ( CurDir() + "\Test" )
 

Re: Where are the files created?

PostPosted: Thu May 27, 2010 5:26 am
by Ross_ValuSoft
Thanks for your reply Antonio.

Yes, I had tried that earlier without any success.

Then I added a simple MsgInfo( CurDir() ) and it shows a blank. This is using the Pocket PC 2003 Second Edition emulator. Could that be the cause?

I think that I will have to continue using the emulator just for on-screen positioning verifications and the real Dell Axim for performance work. Disappointing.

Cheers,

Ross

Re: Where are the files created?

PostPosted: Thu May 27, 2010 7:41 am
by Antonio Linares
Ross,

I have just tested this test.prg example and worked fine as you can see in the screenshot :-)
Code: Select all  Expand view

#include "fwce.ch"

function Main()

   MsgInfo( CurDir() )

return nil
 

Image

Re: Where are the files created?

PostPosted: Thu May 27, 2010 7:58 am
by Ross_ValuSoft
Good morning Antonio ...

Here is mine ...

Image

Re: Where are the files created?

PostPosted: Thu May 27, 2010 8:03 am
by Ross_ValuSoft
I just used your code Antonio and got your result. Something strange at this end of the world. I will dig deeper.

Thanks for your help. Enjoy your Thursday.

Cheers,

Ross

Re: Where are the files created?

PostPosted: Thu May 27, 2010 8:19 am
by Ross_ValuSoft
Solved!

The first of the "pawel" series of programs that I tried, pawel2.prg, had used #include "fwce.ch". Pawel.prg did not!

There is always an explanation ... just have to look very carefully.

Thanks.

Ross ( :oops: )

Re: Where are the files created?

PostPosted: Thu May 27, 2010 8:57 pm
by Antonio Linares
Ross,

good to know that you found the reason :-)

Yes, FWPPC CurDir() is a different code from Harbour's one as there are no drives "names" (C:, ...) in Windows Mobile and fwce.ch replaces it, so it is needed.