View Full Version : Multi-Lined DTMs
serajin
05-11-2012, 03:09 PM
Is it possible to spread a DTM over multiple lines instead of having it on a single line?
masterBB
05-11-2012, 03:11 PM
Is it possible to spread a DTM over multiple lines instead of having it on a single line?
Yes.
a := DTMFromString('hbkjarghbkarghbjzdvbjh'+
'grjahkafalxdnkjgbskjnbgbk34uwh85rhukgnugg'+
'gihulsgnkjgsjgs');
serajin
05-11-2012, 03:14 PM
ah excellent! Thank you for the quick response!
Is there any advantage to this, besides shorter lines. Is it proper form for code, or is this something other members will look down on?
gdsht
05-11-2012, 03:26 PM
Just prevents lines from spilling over margins I think, makes it look neater and easier to read.
It just keeps standards in tact tbh. If the DTM isn't too long then it will go completely unnoticed.
However, if you're DTM is too long that it requires quite a lot scrolling to get to the end, then you should shorten it like shown above.
It won't get you any brownie points nor will it be frowned upon :)
serajin
05-11-2012, 03:28 PM
Oh okay! Thanks. I wasn't sure. I am trying to put some comments in my code, and it's a bit tricky when the comment for the DTM's is like 2 screens over!!
Thank you everyone for the help!
Powered by vBulletin® Version 4.2.1 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.