Welcome, Guest. Please Login
IMPORTANT MESSAGE! This forum has now been replaced by a new forum at http://forum.eastgate.com and no further posting or member registration is allowed. The forum is still accessible via read-only access for reference purposes. If you wish to discuss content here, please use the new forum. N.B. - posting in the new forum requires a fresh registration in the new forum (sorry - member data can't be ported).
Pages: 1
Send Topic Print
Help with RunCommand quoting (Read 1204 times)
Derek Van Ittersum
Full Member

Posts: 168

Help with RunCommand quoting
Dec 13th, 2015, 3:40pm
So I currently have the following stamp which works. I had tried to get the code into a "code note", but couldn't figure out the nested quotations.

-M0-D%20h:mm");$DoUrl2="open '"+$DoUrl+"'";runCommand($DoUrl2)

So basically, I'm URL encoding a few attributes, which I understand. Then I'm, creating the "URL" string out of a few attributes, then storing in the "DoURL" string. Then I need to wrap that string in a quotation before passing to run command, so I do that in by storing it in the "DoURL2" string. It's these last two steps that I think must be unnecessary and can be stored in a Code Note of some sort, right?

here's the basic form of the url that I need to pass to command line:

open "twodo://x-callback-url/add?task=Testing&note=theNote" 

Let me know if I've left out some important variables / details. As I said, it's working as is, I'm just hoping to learn a bit more about using code notes for this sort of process.
Back to top
  IP Logged
Mark Anderson
YaBB Administrator

User - not staff!

Posts: 5689
Southsea, UK
Re: Help with RunCommand quoting
Reply #1 - Dec 13th, 2015, 4:23pm
I think the last two may be run as $DoUrl2 = runcommand('open ', $DoUrl) as per syntax here. But if it works for now, I'd be tempted to leave it alone. The need for 'code notes' arises where there are completx quoting issues - essentially you can run out of different types of quotes to nest.
Back to top
« Last Edit: Dec 13th, 2015, 5:29pm by Mark Anderson »  

Mark Anderson
TB user and Wiki Gardener
aTbRef v6
(TB consulting - email me)
WWW shoantel   IP Logged
Pages: 1
Send Topic Print