Getfile problem with nochangedir

Moderator: Rathinagiri

Post Reply
User avatar
l3whmg
Posts: 694
Joined: Mon Feb 23, 2009 8:46 pm
Location: Italy
Contact:

Getfile problem with nochangedir

Post by l3whmg »

Hi at all,
I found a problem with "GetFile" and "PutFile" functions.
I'm using this syntax:

Code: Select all

Getfile( aFilter, cPrompt, cDir, .F., .F.)
But, the last parameter (NoChangeDir) don't work properly.
I have attached an example, with suggestion.
If you try the example, remember to change the directory, from the current one, to see the problem.

Ciao!
Attachments
GetFileTest.zip
Example
(897 Bytes) Downloaded 298 times
Luigi from Italy
www.L3W.it
User avatar
Roberto Lopez
HMG Founder
Posts: 4004
Joined: Wed Jul 30, 2008 6:43 pm

Re: Getfile problem with nochangedir

Post by Roberto Lopez »

l3whmg wrote:Hi at all,
I found a problem with "GetFile" and "PutFile" functions.
I'm using this syntax:

Code: Select all

Getfile( aFilter, cPrompt, cDir, .F., .F.)
But, the last parameter (NoChangeDir) don't work properly.
I have attached an example, with suggestion.
If you try the example, remember to change the directory, from the current one, to see the problem.

Ciao!
Thanks for the report.

I'll review it ASAP.
Regards/Saludos,

Roberto


(Veritas Filia Temporis)
User avatar
Roberto Lopez
HMG Founder
Posts: 4004
Joined: Wed Jul 30, 2008 6:43 pm

Re: Getfile problem with nochangedir

Post by Roberto Lopez »

l3whmg wrote:Hi at all,
I found a problem with "GetFile" and "PutFile" functions.
I'm using this syntax:

Code: Select all

Getfile( aFilter, cPrompt, cDir, .F., .F.)
But, the last parameter (NoChangeDir) don't work properly.
I have attached an example, with suggestion.
If you try the example, remember to change the directory, from the current one, to see the problem.

Ciao!
You have an error in line #63.

your code:

Code: Select all

cFile := Getfile( { {'All Files','*.*'} }, "File selection", cBefore, .F., .F.)
it should be:

Code: Select all

cFile := Getfile( { {'All Files','*.*'} }, "File selection", cBefore, .F., .T.)
Regards/Saludos,

Roberto


(Veritas Filia Temporis)
User avatar
l3whmg
Posts: 694
Joined: Mon Feb 23, 2009 8:46 pm
Location: Italy
Contact:

Re: Getfile problem with nochangedir

Post by l3whmg »

Yes,
I'm sorry :oops: . I've looked now with your suggestion. I've copied an old program without a good test before and, perhaps, this was an old problem!
Thanks a lot.
Luigi from Italy
www.L3W.it
Post Reply