Zopieux Posted October 13, 2007 Posted October 13, 2007 Hi again, I wonder what is the best way to declare strings : do I have to use double quotes "foo" or single quotes 'foo' ? I ask this question because in the PHP language, it is better to use single quotes, and it could be different with AutoIt... Best regards, Zopieux I'm not English, then please excuse my spelling :)
Developers Jos Posted October 13, 2007 Developers Posted October 13, 2007 there is no better in this case ... just convenience that's all... eg: "that's" is easier than 'that''s' SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
Moderators big_daddy Posted October 13, 2007 Moderators Posted October 13, 2007 The help file gives a good explanation of this under Datatypes.
Zopieux Posted October 13, 2007 Author Posted October 13, 2007 OK, thanks for the tips, I didn't see the "datatypes" chapter. I'm not English, then please excuse my spelling :)
Moderators big_daddy Posted October 13, 2007 Moderators Posted October 13, 2007 OK, thanks for the tips, I didn't see the "datatypes" chapter.You can find it two different ways:Under the index as "Datatypes"Under Contents -->AutoIt -->Language Reference -->Datatypes
therks Posted October 13, 2007 Posted October 13, 2007 I use '. One key press instead of two. My AutoIt Stuff | My Github
aslani Posted October 13, 2007 Posted October 13, 2007 I personally have a problem with single quotation since I often confuse them for apostrophe. Example: $var = 'The ball is not mine, it is Jona's Although this doesn't happen to me all the time, I'd use double quotation just to be on the safe side, since after coding hundred of lines, it's hard to find that kind of mistake. [font="Georgia"]Chances are, I'm wrong.[/font]HotKey trouble?Stringregexp GuideAutoIT Current Version
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now