launch url, spaces in folder names [Solved]

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
magice
Posts: 457
Joined: Wed Mar 18, 2009 12:57 am

launch url, spaces in folder names [Solved]

Post by magice » Tue May 20, 2014 1:26 pm

I am working on a specialized windows app that creates and launches folders as part of a picture organization system that my employer uses. The problem I am running into, is that if any folders along the file path have spaces in their names, the folder is created, but launch url will not open them. Is there a way to get around this?
Last edited by magice on Tue May 20, 2014 4:18 pm, edited 1 time in total.

jmburnod
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2729
Joined: Sat Dec 22, 2007 5:35 pm
Contact:

Re: launch url, spaces in folder names

Post by jmburnod » Tue May 20, 2014 2:49 pm

Hi magice,

Just an ideas (no tested)

Code: Select all

replace " " with "+" in myPath
Best
Jean-Marc
https://alternatic.ch

magice
Posts: 457
Joined: Wed Mar 18, 2009 12:57 am

Re: launch url, spaces in folder names

Post by magice » Tue May 20, 2014 3:21 pm

jmburnod wrote:Hi magice,

Just an ideas (no tested)

Code: Select all

replace " " with "+" in myPath
Best
Jean-Marc
Unfortunately that is not the answer, but I am thinking that maybe a replacement of the spaces is the answer. I'm just not sure what to replace them with.

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 4174
Joined: Sun Jan 07, 2007 9:12 pm

Re: launch url, spaces in folder names

Post by bn » Tue May 20, 2014 3:30 pm

Hi magice,

does

Code: Select all

urlEncode / urlDecode
help?

Kind regards
Bernd

Klaus
Posts: 14205
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: launch url, spaces in folder names

Post by Klaus » Tue May 20, 2014 3:47 pm

...
replace SPACE with "%20" in myPath
...
:D

magice
Posts: 457
Joined: Wed Mar 18, 2009 12:57 am

Re: launch url, spaces in folder names

Post by magice » Tue May 20, 2014 3:57 pm

bn wrote:Hi magice,

does

Code: Select all

urlEncode / urlDecode
help?

Kind regards
Bernd
I actually got my hopes up with that one. I though for sure that it would work, but still no luck.
Klaus wrote:...
replace SPACE with "%20" in myPath
...
:D
I think that is the first answer you have ever given to me that didn't work. Is there any other way to open a windows folder other than "launch url"?

Klaus
Posts: 14205
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: launch url, spaces in folder names

Post by Klaus » Tue May 20, 2014 4:08 pm

Hi Magice,

it DOES work actually, but not in your case :D
I only read "launch url..." and thought about launching a local file in the browser,
where tha line is neccessary.

OK, you are looking for:
...
launch DOCUMENT "path/to/folder with spaces"
...
:D


Best

Klaus

magice
Posts: 457
Joined: Wed Mar 18, 2009 12:57 am

Re: launch url, spaces in folder names [solved]

Post by magice » Tue May 20, 2014 4:17 pm

Klaus wrote:Hi Magice,

it DOES work actually, but not in your case :D
I only read "launch url..." and thought about launching a local file in the browser,
where tha line is neccessary.

OK, you are looking for:
...
launch DOCUMENT "path/to/folder with spaces"
...
:D


Best

Klaus
As usual Klaus, you are the man.

Post Reply