Combining strings? Thread last updated on 2003-06-14 01:04:30

Posted by member 13552 on 2003-06-10 13:19:04

I have a variable that needs to be equal to $filemanager$ followed by $Drives$, something like "$filemanager$ $drives". I've put quotes all over the place, and it still will not work. So how do I combine two variables (strings) into one like that?

- Phil

Posted by member 7 on 2003-06-10 16:22:57 link

Depends on where you're launching it from. Take a look at this and scroll down a bit, I posted an explanation about evars, quotes, and parameters there. HTH

Posted by member 13552 on 2003-06-10 18:09:46 link

err... well i want to say var "$filemanager$ $drives$" or whatever and then later declare a shortcut which uses $var$ as the command executed when the shortcut is clicked on.

Posted by member 1 on 2003-06-10 19:04:21 link

apberzerk - that would be because you are using it wrong. $Drives$ isn't just a CLSID because that would be pretty useless. Try just using $Drives$.

Posted by member 13552 on 2003-06-10 19:15:52 link

doesn't work if you're not using explorer

Posted by member 13552 on 2003-06-10 19:16:40 link

and even if you're using explorer, i think it is screwy... $controls$ definitely doesn't work

Posted by member 1 on 2003-06-10 20:05:19 link

sure does...I just did them both...

*Popup "Test" "$Drives$"

*Popup "Test2" "$Controls$"

Posted by member 36955 on 2003-06-10 22:53:05 link

for me
!execute [$FileManager$ $drives$]
works, not using any quotes, and i have 2xexplorer... only if you put 2xexplorer in your system path though and change the variable to
FileManager 2xexplorer

Posted by member 13552 on 2003-06-12 21:42:00 link

Argh, what i want to do is set a variable equal to
"$drives$" concatenated onto "$filemanager$"...

Posted by member 1 on 2003-06-12 22:34:02 link

Its just...

variable "$FileManager $Drives$"

...like you said before.

Posted by member 13552 on 2003-06-13 12:16:26 link

Heh, is it? Is it really? Try it, cause it sure didn't work for me....

Posted by member 13552 on 2003-06-13 12:18:54 link

Even when I add the $ that I think you missed:

variable "$FileManager$ $Drives$"

Posted by member 5120 on 2003-06-13 17:36:13 link

But he has to be careful with those quotes so that it doesn't get interpreted as a filename with spaces but a filename followed by a parameter.

Posted by member 1 on 2003-06-13 17:43:03 link

I use this all the time...

LoadModule $LiteStepDir$Modules$ThemeName$\mzscript.dll

Posted by member 13552 on 2003-06-13 17:46:29 link

Seriously does not work... you try this...

MyVar "$FileManager$ $Drives$"
*Shortcut "testing" 10 10 "someicon.png" .none .none #7T "$MyVar$"

It will not work for me...

Posted by member 13552 on 2003-06-13 17:47:55 link

DeViLbOi that is not what i am talking about. We all know strings can combine like that, but if you try to set it to a variable and then use that variable... nothing

Posted by member 99 on 2003-06-14 01:02:57 link

See ilmcut's post. (really, that thread is the same problem)

You probably want something like:
MyVar '"$FileManager$" $Drives$'
*Shortcut ... $MyVar$


If you put $MyVar$ in quotes, it will try to make the entire thing into the program's path.

Posted by member 13552 on 2003-06-14 01:04:30 link

Yes, that looks very much like what I want. I'll try it out, thanks!