Inconsistent behavior on DefDir$

Discuss any general programming issues here
Post Reply
ilbarbax
Posts: 82
Joined: Thu Apr 01, 2010 6:41 pm

Inconsistent behavior on DefDir$

Post by ilbarbax » Mon Apr 01, 2019 12:16 pm

Under windows, using FileRequest the defdir$ accepts / as directory separator, while PathRequest does not accepts / but wants \.
I had to use the following sentence:

DefDir$="M:/JOB_ARCHIVE/"

nf$=FileRequest("Select job picture","png|jpg|jpeg|tif|iff|pcx|bmp",#REQ_NORMAL,DefDir$)

nf$=PathRequest("Select where to place your blank job picture",#REQ_NORMAL,ReplaceStr(DefDir$, Chr(47), Chr(92)))

User avatar
airsoftsoftwair
Posts: 3113
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Inconsistent behavior on DefDir$

Post by airsoftsoftwair » Tue Apr 02, 2019 10:11 pm

Good spot, I'll fix this.

User avatar
airsoftsoftwair
Posts: 3113
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Inconsistent behavior on DefDir$

Post by airsoftsoftwair » Mon May 27, 2019 6:12 pm

Code: Select all

- Fix: PathRequest() and FileRequest() didn't allow you to mix slashes and backslashes in the path that
  was passed as the default directory

Post Reply